home *** CD-ROM | disk | FTP | other *** search
/ The Arsenal Files 6 / The Arsenal Files 6 (Arsenal Computer).ISO / prg_gen / inter49b.zip / INTERRUP.E < prev    next >
Text File  |  1996-02-11  |  332KB  |  8,648 lines

  1. Interrupt List, part 5 of 14
  2. Copyright (c) 1989,1990,1991,1992,1993,1994,1995,1996 Ralf Brown
  3. --------D-213F-------------------------------
  4. INT 21 - DOS 2+ - "READ" - READ FROM FILE OR DEVICE
  5.     AH = 3Fh
  6.     BX = file handle
  7.     CX = number of bytes to read
  8.     DS:DX -> buffer for data
  9. Return: CF clear if successful
  10.         AX = number of bytes actually read (0 if at EOF before call)
  11.     CF set on error
  12.         AX = error code (05h,06h) (see #0960 at AH=59h)
  13. Notes:    data is read beginning at current file position, and the file position
  14.       is updated after a successful read
  15.     the returned AX may be smaller than the request in CX if a partial
  16.       read occurred
  17.     if reading from CON, read stops at first CR
  18.     under the FlashTek X-32 DOS extender, the pointer is in DS:EDX
  19. BUG:    Novell NETX.EXE v3.26 and 3.31 do not set CF if the read fails due to
  20.       a record lock (see AH=5Ch), though it does return AX=0005h; this
  21.       has been documented by Novell
  22. SeeAlso: AH=27h,AH=40h,AH=93h,INT 2F/AX=1108h,INT 2F/AX=1229h
  23. --------G-213F-------------------------------
  24. INT 21 - Turbo Debug HARDWARE BREAKPOINTS - READ STATUS BLOCK
  25.     AH = 3Fh
  26.     BX = handle for character device "TDHDEBUG"
  27.     CX = number of bytes to read
  28.     DS:DX -> buffer for status block (see #0704)
  29. Return: CF clear if successful
  30.         AX = number of bytes actually read
  31.     CF set on error
  32.         AX = error code (05h,06h) (see #0960 at AH=59h)
  33. SeeAlso: AH=40h"Turbo Debug"
  34.  
  35. (Table 0703)
  36. Values for status of Turbo Debugger command:
  37.  00h    successful
  38.  01h    invalid handle
  39.  02h    no more breakpoints available
  40.  03h    hardware does not support specified breakpoint type
  41.  04h    previous command prevents execution
  42.  05h    debugger hardware not found
  43.  06h    hardware failure
  44.  07h    invalid command
  45.  08h    driver not initialized yet
  46.  FEh    recursive entry (hardware breakpoint inside hw bp handler)
  47.  
  48. Format of Turbo Debugger status block:
  49. Offset    Size    Description    (Table 0704)
  50.  00h    BYTE    status of command (see #0703)
  51. ---status for command 01h---
  52.  01h    WORD    device driver interface version number (currently 1)
  53.  03h    WORD    device driver software version
  54.  05h    BYTE    maximum simultaneous hardware breakpoints
  55.  06h    BYTE    configuration bits (see #0705)
  56.  07h    BYTE    supported breakpoint types (see #0706)
  57.  08h    WORD    supported addressing match modes (see #0707)
  58.  0Ah    WORD    supported data matches (see #0708)
  59.  0Ch    BYTE    maximum data match length (01h, 02h, or 04h)
  60.  0Dh    WORD    size of onboard memory (in KB)
  61.  0Fh    WORD    maximum number of trace-back events
  62.  11h    WORD    hardware breakpoint enable byte address segment (0000h if not
  63.           supported)
  64. ---status for command 04h---
  65.  01h    BYTE    handle to use when referring to the just-set breakpoint
  66.  
  67. Bitfields for Turbo Debugger configuration bits:
  68. Bit(s)    Description    (Table 0705)
  69.  0    CPU and DMA accesses are distinct
  70.  1    can detect DMA transfers
  71.  2    supports data mask
  72.  3    hardware pass counter on breakpoints
  73.  4    can match on data as well as addresses
  74.  
  75. Bitfields for Turbo Debugger supported breakpoint types:
  76. Bit(s)    Description    (Table 0706)
  77.  0    memory read
  78.  1    memory write
  79.  2    memory read/write
  80.  3    I/O read
  81.  4    I/O write
  82.  5    I/O read/write
  83.  6    instruction fetch
  84.  
  85. Bitfields for Turbo Debugger supported addressing match modes:
  86. Bit(s)    Description    (Table 0707)
  87.  0    any address
  88.  1    equal to test value
  89.  2    not equal
  90.  3    above test value
  91.  4    below test value
  92.  5    below or equal
  93.  6    above or equal
  94.  7    within range
  95.  8    outside range
  96.  
  97. Bitfields for Turbo Debugger supported data matches:
  98. Bit(s)    Description    (Table 0708)
  99.  0    any data
  100.  1    equal to test value
  101.  2    not equal
  102.  3    above test value
  103.  4    below test value
  104.  5    below or equal
  105.  6    above or equal
  106.  7    within range
  107.  8    outside range
  108. --------N-213F-------------------------------
  109. INT 21 - PC/TCP IPCUST.SYS - READ CONFIGURATION DATA
  110.     AH = 3Fh
  111.     BX = handle for character device "$IPCUST"
  112.     CX = number of bytes to read
  113.     DS:DX -> buffer for configuration data (see #0709)
  114. Return: CF clear if successful
  115.         AX = number of bytes actually read
  116.     CF set on error
  117.         AX = error code (05h,06h) (see #0960 at AH=59h)
  118. Notes:    if less than the entire data is read or written, the next read/write
  119.       continues where the previous one ended; IOCTL calls AX=4402h and
  120.       AX=4403h both reset the location at which the next operation starts
  121.       to zero
  122.     the data pointer is also reset to zero if the previous read or write
  123.       reached or exceeded the end of the data, when the current function
  124.       is read and the previous was write, or vice versa
  125.     v2.1+ uses a new configuration method, but allows the installation
  126.       of IPCUST.SYS for backward compatibility with other software which
  127.       must read the PC/TCP configuration
  128. SeeAlso: AH=40h"IPCUST",AX=4402h"IPCUST",AX=4402h"FTPSOFT"
  129.  
  130. Format of PC/TCP configuration data:
  131. Offset    Size    Description    (Table 0709)
  132.  00h 12 BYTEs    IPCUST.SYS device driver header
  133.  12h    BYTE    ???
  134.  13h    BYTE    ???
  135.  14h    WORD    ???
  136.  16h    BYTE    bit flags
  137.         bit 0: send BS rather than DEL for BackSpace key
  138.         bit 1: wrap long lines
  139.  17h    BYTE    ???
  140.  18h 64 BYTEs    ASCIZ hostname
  141.  58h 64 BYTEs    ASCIZ domain name
  142.         (fully qualified domain name is hostname.domain-name)
  143.  98h 16 BYTEs    ASCIZ username
  144.  A8h 64 BYTEs    ASCIZ full name
  145.  E8h 64 BYTEs    ASCIZ office address
  146. 128h 32 BYTEs    ASCIZ phone number
  147. 148h    WORD    offset from GMT in minutes
  148. 14Ah  4 BYTEs    ASCIZ timezone name
  149. 14Eh    WORD    number of time servers
  150. 150h  ? DWORDs    (big-endian) IP addresses for time servers
  151.     ???
  152. 164h    WORD    number of old-style name servers
  153. 166h  3 DWORDs    (big-endian) IP addresses for name servers
  154. 172h    WORD    number of domain name servers
  155. 174h  3 DWORDs    (big-endian) IP addresses for domain name servers
  156. 180h    DWORD    (big-endian) IP address of default gateway
  157. 184h    DWORD    (big-endian) IP address of log server
  158. 188h    DWORD    (big-endian) IP address of cookie server
  159. 18Ch    DWORD    (big-endian) IP address of lpr server
  160. 190h    DWORD    (big-endian) IP address of imagen print server
  161. 194h 54 BYTEs    ???
  162. 1E8h    WORD    TCP default window size in bytes
  163. 1EAh    WORD    TCP low window size
  164. 1ECh 64 BYTEs    ASCIZ host tabel filename
  165. 22Ch  2 BYTEs    ???
  166. 22Eh 80 BYTEs    ASCIZ mail relay host name
  167. 27Eh    BYTE    ???
  168. 27Fh    BYTE    ??? bit flags
  169. 280h 44 BYTEs    ???
  170. 2ACh    WORD    ???
  171. 2AEh 202 BYTEs    ???
  172. --------N-213F-------------------------------
  173. INT 21 - WORKGRP.SYS - GET ENTRY POINT
  174.     AH = 3Fh
  175.     BX = file handle for device "NET$HLP$"
  176.     CX = 0008h
  177.     DS:DX -> buffer for entry point record (see #0779)
  178. Return: CF clear if successful
  179.         AX = number of bytes actually read (0 if at EOF before call)
  180.     CF set on error
  181.         AX = error code (05h,06h) (see #0960 at AH=59h)
  182. Program: WORKGRP.SYS is the portion of Microsoft's Workgroup Connection which
  183.       permits communication with PCs running Windows for Workgroups or
  184.       LAN Manager
  185. SeeAlso: AX=4402h"WORKGRP.SYS",INT 2F/AX=9400h
  186. --------N-213F-------------------------------
  187. INT 21 - BW-TCP - GET DRIVER INFO
  188.     AH = 3Fh
  189.     BX = file handle for device "ETHDEV27"
  190.     CX = 002Bh
  191.     DS:DX -> buffer for driver info (see #0710)
  192. Return: CF clear if successful
  193.         AX = number of bytes actually read (0 if at EOF before call)
  194.     CF set on error
  195.         AX = error code (05h,06h) (see #0960 at AH=59h)
  196. Program: BW-TCP is a TCP/IP protocol stack by Beame & Whiteside Software
  197. Notes:    the B&W socket library performs an INT 21/AX=4401h with DX=0060h before
  198.       making this call to retrieve the driver information; one should also
  199.       call the private API interrupt with AH=15h
  200.     the installation check for the TCP/IP stack is to test for the
  201.       existence of the character device UDP-IP10
  202. SeeAlso: INT 14/AH=56h,INT 62/AH=00h"ETHDEV",INT 63/AH=03h,INT 64/AH=00h
  203. Index:    installation check;BW-TCP hardware driver
  204. Index:    installation check;BW-TCP TCPIP.SYS
  205.  
  206. Format of BW-TCP driver info:
  207. Offset    Size    Description    (Table 0710)
  208.  00h    WORD    I/O base address
  209.  02h    BYTE    shared memory page (01h = segment 0100h, etc.)
  210.  03h    BYTE    interrupt vector for private API
  211.  04h    BYTE    IRQ used by board
  212.  05h    WORD    size of data buffer
  213.  07h    WORD    maximum transfer window
  214.  09h    WORD    time zone
  215.  0Bh    BYTE    address type (01h user, 04h RARP, 05h BOOTP)
  216.  0Ch    DWORD    internet address
  217.  10h    WORD    "value" ???
  218.  12h    BYTE    subnet mask
  219.  13h    WORD    "ether_pointer" ???
  220.  15h    WORD    offset in device driver of log server records (see #0711)
  221.  17h    WORD    offset in device driver of name server records (see #0711)
  222.  19h    WORD    offset in device driver of print server records (see #0711)
  223.  1Bh    WORD    offset in device driver of time server records (see #0711)
  224.  1Dh    WORD    offset in device driver of gateway records (see #0711)
  225.  1Fh    WORD    segment address of device driver
  226.  21h    BYTE    transfer size
  227.  22h  9 BYTEs    network adapter board name
  228. ---11/21/91+ ---
  229.  23h    BYTE    ETHDEV version (major in high nybble, minor in low nybble)
  230.  24h    BYTE    ETHDEV revision
  231.  25h    BYTE    TCPIP version (major in high nybble, minor in low nybble)
  232.  26h    BYTE    TCPIP revision
  233.  27h    BYTE    BWRPC version (major in high nybble, minor in low nybble)
  234.  28h    BYTE    BWRPC revision
  235.  29h    BYTE    BWNFS version (major in high nybble, minor in low nybble)
  236.  2Ah    BYTE    BWNFS revision
  237.  2Bh    BYTE    Telnet version (major in high nybble, minor in low nybble)
  238.  2Ch    BYTE    Telnet revision
  239.  2Dh    BYTE    NETBIOS version (major in high nybble, minor in low nybble)
  240.  2Eh    BYTE    NETBIOS revision
  241. Note:    for each driver, if version=0, the driver is not installed or does
  242.       not support the version check
  243.  
  244. Format of BW-TCP server records:
  245. Offset    Size    Description    (Table 0711)
  246.  00h    BYTE    number of server records following
  247.  01h  N DWORDs    internet addresses of servers
  248. --------y-213F-------------------------------
  249. INT 21 - Trusted Access - NB.SYS - GET STATE
  250.     AH = 3Fh
  251.     BX = file handle for device "$$NB$$NB"
  252.     CX = 0002h (size of state)
  253.     DS:DX -> buffer for state record (see #0712)
  254. Return: CF clear if successful
  255.         AX = number of bytes actually read (0 if at EOF before call)
  256.     CF set on error
  257.         AX = error code (05h,06h) (see #0960 at AH=59h)
  258. Program: Trusted Access is a security and access-control package by Lassen
  259.       Software, Inc.; NB.SYS is a device driver to prevent the user from
  260.       terminating CONFIG.SYS or AUTOEXEC.BAT with Ctrl-Break
  261. SeeAlso: AH=40h"NB.SYS",AX=4101h
  262.  
  263. Format of Trusted Access state record:
  264. Offset    Size    Description    (Table 0712)
  265.  00h    BYTE    00h off, 01h on
  266.  01h    BYTE    keys being disabled
  267.         bit 0: Ctrl-Break
  268.         bit 1: SysReq
  269.         bit 2: Ctrl and Alt
  270.         bit 3: Ctrl-Alt-Del
  271.         bit 7: all keys (overrides other bits)
  272. ----------213F-------------------------------
  273. INT 21 U - IFSHLP.SYS - GET ENTRY POINT
  274.     AH = 3Fh
  275.     BX = file handle for device "IFS$HLP$"
  276.     CX = 0008h (size of buffer in bytes)
  277.     DS:DX -> buffer for entry point record (see #0713)
  278. Return: CF clear if successful
  279.         AX = number of bytes actually read (0 if at EOF before call)
  280.     CF set on error
  281.         AX = error code (05h,06h) (see #0960 at AH=59h)
  282. Program: IFSHLP.SYS is a support driver for Microsoft Windows for Workgroups
  283. SeeAlso: AX=4402h"IFSHLP"
  284.  
  285. Format of IFSHLP.SYS entry point record:
  286. Offset    Size    Description    (Table 0713)
  287.  00h  4 BYTEs    (call) signature 70h E9h 34h 37h
  288.         signature must be 34h 37h 70h EFh if called via IOCTL
  289.  04h    DWORD    (ret) pointer to FAR call entry point (see #0714)
  290.  
  291. (Table 0714)
  292. Call IFSHLP.SYS entry point with:
  293.     STACK:    WORD    function number (00h-0Ch)
  294.             00h ???
  295.             01h set ??? intercept
  296.             02h remove ??? intercept
  297.             03h ??? LPT2
  298.             04h ??? LPT1
  299.             05h ??? and remove ??? intercept
  300.             06h set ??? flag
  301.             07h clear ??? flag
  302.             08h get ??? flag word
  303.             09h ???
  304.             0Ah ???
  305.             0Bh ???
  306.             0Ch get ???
  307. ---if function 00h---
  308. Return: AX = ??? (0024h seen)
  309.     DX = resident code segment
  310. ---if function 01h---
  311.     STACK:    DWORD    new intercept address
  312. Return: AX = status
  313.         0000h successful
  314.         0001h failed (already set)
  315.         DX = 0000h
  316. ---if function 02h---
  317. Return: AX = status
  318.         0000h successful
  319.         0001h failed (not set)
  320.     DX = 0000h
  321. ---if function 03h,04h---
  322.     STACK:    WORD    ???
  323. Return: AX = 0000h
  324.     DX = 0000h
  325. ---if function 05h---
  326.     ???
  327. ---if function 06h---
  328. Return: AX = 0001h and DX = 0000h if already set
  329.     AX,DX unchanged if successful
  330. ---if function 07h---
  331. Return: AX = 0001h and DX = 0000h if not set
  332.     AX,DX unchanged if successful
  333. ---if function 08h---
  334. Return: DX = 0000h
  335.     AX = flags (bit 0 set/cleared by functions 06h and 07h)
  336. ---if function 09h---
  337. Return: AX = status
  338.         0000h successful
  339.         0001h failed (already called)
  340. ---if function 0Ah---
  341.     STACK:    WORD    ???
  342.     ???
  343. ---if function 0Bh---
  344. Return: AX = status
  345.         0000h successful
  346.         0001h failed (not set)
  347. ---if function 0Ch---
  348. Return: AX = 0000h
  349.     ES:BX -> ??? data
  350. ---if function > 0Ch---
  351. Return:    AX = 0001h
  352.     DX = 0000h
  353. --------v-213F--BXFEB0-----------------------
  354. INT 21 - VIRUS - "KYZ/LieWait" - INSTALLATION CHECK
  355.     AH = 3Fh
  356.     BX = FEB0h
  357. Return: BX = 1212h if resident
  358. SeeAlso: AX=3032h"VIRUS",AX=4BF1h"VIRUS"
  359. --------D-2140-------------------------------
  360. INT 21 - DOS 2+ - "WRITE" - WRITE TO FILE OR DEVICE
  361.     AH = 40h
  362.     BX = file handle
  363.     CX = number of bytes to write
  364.     DS:DX -> data to write
  365. Return: CF clear if successful
  366.         AX = number of bytes actually written
  367.     CF set on error
  368.         AX = error code (05h,06h) (see #0960 at AH=59h)
  369. Notes:    if CX is zero, no data is written, and the file is truncated or
  370.       extended to the current position
  371.     data is written beginning at the current file position, and the file
  372.       position is updated after a successful write
  373.     the usual cause for AX < CX on return is a full disk
  374. BUG:    a write of zero bytes will appear to succeed when it actually failed
  375.       if the write is extending the file and there is not enough disk
  376.       space for the expanded file (DOS 5.0-6.0); one should therefore check
  377.       whether the file was in fact extended by seeking to 0 bytes from
  378.       the end of the file (INT 21/AX=4202h/CX=0/DX=0)
  379.     under the FlashTek X-32 DOS extender, the pointer is in DS:EDX
  380. SeeAlso: AH=28h,AH=3Fh,AH=93h,INT 2F/AX=1109h
  381. --------G-2140-------------------------------
  382. INT 21 - Turbo Debug HARDWARE BREAKPOINTS - SEND CMD TO HARDWARE BRKPNT DRIVER
  383.     AH = 40h
  384.     BX = handle for character device "TDHDEBUG"
  385.     CX = number of bytes to write
  386.     DS:DX -> hardware breakpoint command (see #0715)
  387. Return: CF clear if successful
  388.         AX = number of bytes actually written
  389.     CF set on error
  390.         AX = error code (05h,06h) (see #0960 at AH=59h)
  391. Note:    results are retrieved by reading from the device
  392. SeeAlso: AH=3Fh"Turbo Debug"
  393.  
  394. Format of Turbo Debugger hardware breakpoint commands:
  395. Offset    Size    Description    (Table 0715)
  396.  00h    BYTE    command code
  397.         00h install interrupt vectors
  398.         01h get hardware capabilities
  399.         02h enable hardware breakpoints
  400.         03h disable hardware breakpoints
  401.         04h set hardware breakpoint
  402.         05h clear hardware breakpoint
  403.         06h set I/O base address and reset hardware
  404.         07h restore interrupt vectors
  405. ---command code 00h---
  406.  01h    DWORD    pointer to Turbo Debugger entry point to be jumped to on
  407.           hardware breakpoint; call with CPU state the same as on
  408.           the breakpoint except for pushing AX and placing an entry
  409.           code (FFh if breakout button or breakpoint handle) in AH
  410. ---command code 04h---
  411.  01h    BYTE    breakpoint type
  412.         00h memory read
  413.         01h memory write
  414.         02h memory read/write
  415.         03h I/O read
  416.         04h I/O write
  417.         05h I/O read/write
  418.         06h instruction fetch
  419.  02h    BYTE    address matching mode (see #0716)
  420.  03h    DWORD    32-bit linear low address
  421.  07h    DWORD    32-bit linear high address
  422.  0Bh    WORD    pass count
  423.  0Dh    BYTE    data size (01h, 02h, or 04h)
  424.  0Eh    BYTE    source of matched bus cycle (01h CPU, 02h DMA, 03h either)
  425.  0Fh    BYTE    data-matching mode (see #0716)
  426.  10h    DWORD    low data value
  427.  14h    DWORD    high data value
  428.  18h    DWORD    data mask specifying which bits of the data are tested
  429. ---command code 05h---
  430.  01h    BYTE    handle of breakpoint to clear (breakpoint returned from command
  431.           04h)
  432. ---command code 06h---
  433.  01h    WORD    base address of hardware debugger board
  434.  
  435. (Table 0716)
  436. Values for Turbo Debugger address/data matching mode:
  437.  00h    match any
  438.  01h    equal to test value
  439.  02h    different from test value
  440.  03h    above test value
  441.  04h    below test value
  442.  05h    below or equal to test value
  443.  06h    above or equal to test value
  444.  07h    within inclusive range
  445.  08h    outside specified range
  446. --------N-2140-------------------------------
  447. INT 21 - PC/TCP IPCUST.SYS - WRITE CONFIGURATION DATA
  448.     AH = 40h
  449.     BX = handle for character device "$IPCUST"
  450.     CX = number of bytes to write
  451.     DS:DX -> buffer for configuration data (AH=3Fh"IPCUST")
  452. Return: CF clear if successful
  453.         AX = number of bytes actually written
  454.     CF set on error
  455.         AX = error code (05h,06h) (see #0960 at AH=59h)
  456. Notes:    if less than the entire data is read or written, the next read/write
  457.       continues where the previous one ended; IOCTL calls AX=4402h and
  458.       AX=4403h both reset the location at which the next operation starts
  459.       to zero
  460.     the data pointer is also reset to zero if the previous read or write
  461.       reached or exceeded the end of the data, when the current function
  462.       is read and the previous was write, or vice versa
  463.     v2.1+ uses a new configuration method, but allows the installation
  464.       of IPCUST.SYS for backward compatibility with other software which
  465.       must read the PC/TCP configuration
  466. SeeAlso: AH=3Fh"IPCUST",AX=4402h"IPCUST"
  467. --------y-2140-------------------------------
  468. INT 21 U - Trusted Access - NB.SYS - SET STATE
  469.     AH = 40h
  470.     BX = handle for character device "$$NB$$NB"
  471.     DS:DX -> state record (see #0712)
  472.     CX ignored
  473. Return: CF clear if successful
  474.         AX = number of bytes actually written
  475.     CF set on error
  476.         AX = error code (05h,06h) (see #0960 at AH=59h)
  477. Program: Trusted Access is a security and access-control package by Lassen
  478.       Software, Inc.; NB.SYS is a device driver to prevent the user from
  479.       terminating CONFIG.SYS or AUTOEXEC.BAT with Ctrl-Break
  480. SeeAlso: AH=3Fh"NB.SYS"
  481. --------j-214000BX0002-----------------------
  482. INT 21 - FARTBELL.EXE - INSTALLATION CHECK
  483.     AX = 4000h
  484.     BX = 0002h
  485.     CX = 0000h
  486.     DS:DX = 0000h:0000h
  487. Return: CF clear if installed
  488.         AX = CS of resident code
  489. Program: FARTBELL is a joke program by Guenther Thiele which makes various
  490.       noises when programs output a bell
  491. SeeAlso: AX=4001h
  492. --------j-214001BX0002-----------------------
  493. INT 21 - FARTBELL.EXE - FORCE NOISE
  494.     AX = 4001h
  495.     BX = 0002h
  496.     CX = 0000h
  497.     DS:DX = 0000h:0000h
  498. Program: FARTBELL is a joke program by Guenther Thiele which makes various
  499.       noises when programs output a bell
  500. SeeAlso: AX=4000h
  501. --------D-2141-------------------------------
  502. INT 21 - DOS 2+ - "UNLINK" - DELETE FILE
  503.     AH = 41h
  504.     DS:DX -> ASCIZ filename (no wildcards, but see notes)
  505.     CL = attribute mask for deletion (server call only, see notes)
  506. Return: CF clear if successful
  507.         AX destroyed (DOS 3.3) AL seems to be drive of deleted file
  508.     CF set on error
  509.         AX = error code (02h,03h,05h) (see #0960 at AH=59h)
  510. Notes:    (DOS 3.1+) wildcards are allowed if invoked via AX=5D00h, in which case
  511.       the filespec must be canonical (as returned by AH=60h), and only
  512.       files matching the attribute mask in CL are deleted
  513.     DR DOS 5.0-6.0 returns error code 03h if invoked via AX=5D00h; DR DOS
  514.       3.41 crashes if called via AX=5D00h with wildcards
  515.     DOS does not erase the file's data; it merely becomes inaccessible
  516.       because the FAT chain for the file is cleared
  517.     deleting a file which is currently open may lead to filesystem
  518.       corruption.  Unless SHARE is loaded, DOS does not close the handles
  519.       referencing the deleted file, thus allowing writes to a nonexistant
  520.       file.
  521.     under DR DOS and DR Multiuser DOS, this function will fail if the file
  522.       is currently open
  523.     under the FlashTek X-32 DOS extender, the pointer is in DS:EDX
  524. BUG:    DR DOS 3.41 crashes if called via AX=5D00h
  525. SeeAlso: AH=13h,AX=4301h,AX=4380h,AX=5D00h,AH=60h,AH=71h,AX=F244h
  526. SeeAlso: INT 2F/AX=1113h
  527. --------y-214101DXFFFE-----------------------
  528. INT 21 - SoftLogic Data Guardian - ???
  529.     AX = 4101h
  530.     DX = FFFEh
  531. Return: AX = 0000h if installed
  532. Note:    resident code sets several internal variables on this call
  533. SeeAlso: AH=3Fh"NB.SYS",INT 16/AX=FFA3h/BX=0000h
  534. --------D-2142-------------------------------
  535. INT 21 - DOS 2+ - "LSEEK" - SET CURRENT FILE POSITION
  536.     AH = 42h
  537.     AL = origin of move
  538.         00h start of file
  539.         01h current file position
  540.         02h end of file
  541.     BX = file handle
  542.     CX:DX = offset from origin of new file position
  543. Return: CF clear if successful
  544.         DX:AX = new file position in bytes from start of file
  545.     CF set on error
  546.         AX = error code (01h,06h) (see #0960 at AH=59h)
  547. Notes:    for origins 01h and 02h, the pointer may be positioned before the
  548.       start of the file; no error is returned in that case, but subsequent
  549.       attempts at I/O will produce errors
  550.     if the new position is beyond the current end of file, the file will
  551.       be extended by the next write (see AH=40h)
  552. BUG:    using this method to grow a file from zero bytes to a very large size
  553.       can corrupt the FAT in some versions of DOS; the file should first
  554.       be grown from zero to one byte and then to the desired large size
  555. SeeAlso: AH=24h,INT 2F/AX=1228h
  556. --------v-214203-----------------------------
  557. INT 21 - VIRUS - "Shake" - INSTALLATION CHECK
  558.     AX = 4203h
  559. Return: AX = 1234h if resident
  560. SeeAlso: AX=3DFFh,AX=4243h
  561. --------v-214243-----------------------------
  562. INT 21 - VIRUS - "Invader" - INSTALLATION CHECK
  563.     AX = 4243h
  564. Return: AX = 5678h if resident
  565. SeeAlso: AX=4203h,AX=4B04h
  566. --------D-214300-----------------------------
  567. INT 21 - DOS 2+ - GET FILE ATTRIBUTES
  568.     AX = 4300h
  569.     DS:DX -> ASCIZ filename
  570. Return: CF clear if successful
  571.         CX = file attributes (see #0717)
  572.         AX = CX (DR DOS 5.0)
  573.     CF set on error
  574.         AX = error code (01h,02h,03h,05h) (see #0960 at AH=59h)
  575. Notes:    under the FlashTek X-32 DOS extender, the filename pointer is in DS:EDX
  576.     under DR DOS 3.41 and 5.0, attempts to change the subdirectory bit are
  577.       simply ignored without an error
  578. BUG:    Windows for Workgroups returns error code 05h (access denied) instead
  579.       of error code 02h (file not found) when attempting to get the
  580.       attributes of a nonexistent file.  This causes open() with O_CREAT
  581.       and fopen() with the "w" mode to fail in Borland C++.
  582. SeeAlso: AX=4301h,AX=4310h,AH=71h,AH=B6h,INT 2F/AX=110Fh,INT 60/DI=0517h
  583. --------D-214301-----------------------------
  584. INT 21 - DOS 2+ - "CHMOD" - SET FILE ATTRIBUTES
  585.     AX = 4301h
  586.     CX = new file attributes (see #0717)
  587.     DS:DX -> ASCIZ filename
  588. Return: CF clear if successful
  589.         AX destroyed
  590.     CF set on error
  591.         AX = error code (01h,02h,03h,05h) (see #0960 at AH=59h)
  592. Notes:    will not change volume label or directory attribute bits, but will
  593.       change the other attribute bits of a directory (the directory
  594.       bit must be cleared to successfully change the other attributes of a
  595.       directory, but the directory will not be changed to a normal file as
  596.       a result)
  597.     MS-DOS 4.01 reportedly closes the file if it is currently open
  598.     for security reasons, the Novell NetWare execute-only bit can never
  599.       be cleared; the file must be deleted and recreated
  600.     under the FlashTek X-32 DOS extender, the filename pointer is in DS:EDX
  601.     DOS 5.0 SHARE will close the file if it is currently open in sharing-
  602.       compatibility mode, otherwise a sharing violation critical error is
  603.       generated if the file is currently open
  604.     DR DOS 3.41/5.0 will silently ignore attempts to change the 'directory'
  605.       attribute bit
  606. SeeAlso: AX=4300h,AX=4311h,AH=71h,INT 2F/AX=110Eh
  607.  
  608. Bitfields for file attributes:
  609. Bit(s)    Description    (Table 0717)
  610.  7    shareable (Novell NetWare)
  611.  6    unused
  612.  5    archive
  613.  4    directory
  614.  3    volume label
  615.     execute-only (Novell NetWare)
  616.  2    system
  617.  1    hidden
  618.  0    read-only
  619. --------D-214302-----------------------------
  620. INT 21 - DOS 7 (Chicago) - GET VOLUME INFORMATION
  621.     AX = 4302h
  622.     details not yet available
  623. SeeAlso: AH=71h,AH=72h
  624. --------O-214302-----------------------------
  625. INT 21 - DR DOS 3.41+ internal - GET ACCESS RIGHTS
  626.     AX = 4302h
  627.     DS:DX -> ASCIZ pathname
  628. Return: CF clear if successful
  629.         CX = access rights (see #0718)
  630.         AX = CX (DR DOS 5.0)
  631.     CF set on error
  632.         AX = error code
  633. Desc:    Determine which operations the calling program may perform on a
  634.       specified file without being required to provide a password.
  635. Notes:    this protection scheme has been coordinated on all current Digital
  636.       Research/Novell operating systems (DR DOS 3.41+, DRMDOS 5.x, and
  637.       FlexOS 2+)
  638.     this function is documented in DR DOS 6.0 and corresponds to the
  639.       "Get/Set File Attributes" function, subfunction 2, documented in
  640.       Concurrent DOS.
  641.     only FlexOS actually uses the "execution" bits; DR DOS 3.41+ treats
  642.       them as "read" bits.
  643.     DR DOS 3.41-5.x only use bits 0-3.  Only DR DOS 6.0 using a
  644.       DRMDOS 5.x security system allowing for users and groups uses bits
  645.       4-11.
  646. SeeAlso: AX=4303h
  647.  
  648. Bitfields for DR DOS file access rights:
  649. Bit(s)    Description    (Table 0718)
  650.  0    owner delete requires password
  651.  1    owner execution requires password (FlexOS)
  652.  2    owner write requires password
  653.  3    owner read requires password
  654.  4    group delete requires password
  655.  5    group execution requires password (FlexOS)
  656.  6    group write requires password
  657.  7    group read requires password
  658.  8    world delete requires password
  659.  9    world execution requires password (FlexOS)
  660.  10    world write requires password
  661.  11    world read requires password
  662. --------O-214303-----------------------------
  663. INT 21 - DR DOS 3.41+ internal - SET ACCESS RIGHTS AND PASSWORD
  664.     AX = 4303h
  665.     CX = access rights
  666.          bits 11-0: access rights (see #0718)
  667.          bit 15: new password is to be set
  668.     DS:DX -> ASCIZ pathname
  669.     [DTA] = new password if CX bit 15 is set (blank-padded to 8 characters)
  670. Return: CF clear if successful
  671.     CF set on error
  672.         AX = error code
  673. Notes:    if the file is already protected, the old password must be added after
  674.       the pathname, separated by a ";"
  675.     this function is documented in DR DOS 6.0 and corresponds to the
  676.       "Get/Set File Attributes" function, subfunction 3, documented in
  677.       Concurrent DOS.
  678. SeeAlso: AH=0Fh,AH=17h,AX=4302h"DR DOS",AX=4305h,AX=4454h
  679. --------O-214304-----------------------------
  680. INT 21 U - DR DOS 5.0-6.0 internal - GET ENCRYPTED PASSWORD
  681.     AX = 4304h
  682.     DS:DX -> ASCIZ filename
  683.     ???
  684. Return: CF clear if successful
  685.         CX = AX = 0000h if no password assigned to file
  686.     CF set on error
  687.         AX = error code (see #0960 at AH=59h)
  688. Note:    this function is only supported by DR DOS 5.0 and 6.0 and DRMDOS 5.1
  689. SeeAlso: AX=4303h,AX=4305h
  690. --------O-214305-----------------------------
  691. INT 21 U - DR DOS 5.0-6.0 internal - SET EXTENDED FILE ATTRIBUTES
  692.     AX = 4305h
  693.     DS:DX -> ASCIZ filename
  694.     ???
  695. Return: CF clear if successful
  696.     CF set on error
  697.         AX = error code (see #0960 at AH=59h)
  698. Desc:    this function allows the extended attributes, and optionally the
  699.       encrypted password, of a file to be set.
  700. Note:    this function is only supported by DR DOS 5.0 and 6.0 and DRMDOS 5.1
  701. SeeAlso: AX=4304h,AX=4311h
  702. --------O-214306-----------------------------
  703. INT 21 - DR DOS 6.0 - GET FILE OWNER
  704.     AX = 4306h
  705.     DS:DX -> ASCIZ filename
  706. Return: CF clear if successful
  707.         AX = CX = value set with AX=4307h
  708.     CF set on error
  709.         AX = error code (see #0960 at AH=59h)
  710. SeeAlso: AX=4307h
  711. --------O-214307-----------------------------
  712. INT 21 - DR DOS 6.0 - SET FILE OWNER
  713.     AX = 4307h
  714.     CX = ??? (owner identification number?)
  715.     DS:DX -> ASCIZ filename
  716. Return: CF clear if successful
  717.     CF set on error
  718.         AX = error code (see #0960 at AH=59h)
  719. SeeAlso: AX=4306h
  720. --------N-214310-----------------------------
  721. INT 21 - Banyan VINES 2.1+ - GET EXTENDED FILE ATTRIBUTES
  722.     AX = 4310h
  723.     DS:DX -> ASCIZ filename
  724. Return: CF clear if successful
  725.         CH = attributes (see #0719)
  726.     CF set on error
  727.         AX = error code (01h,02h,03h,05h) (see #0960 at AH=59h)
  728. Note:    the filename may be a directory but must be on a VINES file service
  729. SeeAlso: AX=4300h,AX=4311h,AH=B6h,INT 2F/AX=110Fh
  730. --------N-214311-----------------------------
  731. INT 21 - Banyan VINES 2.1+ - SET EXTENDED FILE ATTRIBUTES
  732.     AX = 4311h
  733.     CH = new attributes (see #0719)
  734.     DS:DX -> ASCIZ filename
  735. Return: CF clear if successful
  736.     CF set on error
  737.         AX = error code (01h,02h,03h,05h) (see #0960 at AH=59h)
  738. Note:    the filename may be a directory but must be on a VINES file service
  739. SeeAlso: AX=4301h,AX=4305h,AX=4310h,INT 2F/AX=110Eh
  740.  
  741. Bitfields for VINES extended file attributes:
  742. Bit(s)    Description    (Table 0719)
  743.  7    unused
  744.  6    shareable
  745.  5    execute-only
  746.  4-0    unused
  747. --------u-214321BX0000-----------------------
  748. INT 21 - Q87, Q387 - INSTALLATION CHECK
  749.     AX = 4321h
  750.     BX = 0000h
  751.     EAX = 87654321h (entire EAX value is required, not just AX)
  752. Return: EAX = 12345678h if installed
  753. Program: Q387 (renamed to Q87 as of v3.7) is a math coprocessor emulator from
  754.       Quickware
  755. Note:    this function is available only in virtual-86 mode in older versions;
  756.       newer versions also provide it in MS Windows 16- and 32-bit protected
  757.       mode
  758. SeeAlso: AX=4321h/BX=0001h,AX=4321h/BX=0002h,INT 67/AX=4321h
  759. --------u-214321BX0001-----------------------
  760. INT 21 - Q87, Q387 - ENABLE EMULATOR
  761.     AX = 4321h
  762.     BX = 0001h
  763.     EAX = 87654321h (entire EAX value is required, not just AX)
  764. Desc:    enable the emulator by setting the CPU MSW's EM bit and updating
  765.       the BIOS equipment list
  766. Note:    this function is available only in virtual-86 mode in older versions;
  767.       newer versions also provide it in MS Windows 16- and 32-bit protected
  768.       mode
  769. SeeAlso: AX=4321h/BX=0000h,AX=4321h/BX=0002h
  770. --------u-214321BX0002-----------------------
  771. INT 21 - Q87, Q387 - DISABLE EMULATOR
  772.     AX = 4321h
  773.     BX = 0002h
  774.     EAX = 87654321h (entire EAX value is required, not just AX)
  775. Desc:    disable the emulator by clearing the CPU MSW's EM bit and updating
  776.       the BIOS equipment list
  777. Note:    this function is available only in virtual-86 mode in older versions;
  778.       newer versions also provide it in MS Windows 16- and 32-bit protected
  779.       mode
  780. SeeAlso: AX=4321h/BX=0000h,AX=4321h/BX=0001h
  781. --------O-214380-----------------------------
  782. INT 21 - Novell DOS 7 - UNDELETE PENDING DELETE FILE
  783.     AX = 4380h
  784.     ???
  785. Return: ???
  786. SeeAlso: AH=41h,AX=4381h
  787. --------O-214381-----------------------------
  788. INT 21 - Novell DOS 7 - PURGE PENDING DELETE FILE
  789.     AX = 4381h
  790.     ???
  791. Return: ???
  792. SeeAlso: AH=41h,AX=4380h
  793. --------D-214400-----------------------------
  794. INT 21 - DOS 2+ - IOCTL - GET DEVICE INFORMATION
  795.     AX = 4400h
  796.     BX = handle
  797. Return: CF clear if successful
  798.         DX = device information word (see #0720)
  799.         AX destroyed
  800.     CF set on error
  801.         AX = error code (01h,05h,06h) (see #0960 at AH=59h)
  802. Notes:    value in DH corresponds to high byte of device driver's attribute word
  803.       if handle refers to a character device
  804.     Novell NetWare reportedly does not return a drive number in bits 5-0
  805.       for a disk file
  806. SeeAlso: AX=4401h,INT 2F/AX=122Bh
  807.  
  808. Bitfields for device information word:
  809. Bit(s)    Description    (Table 0720)
  810.  character device
  811.   14    device driver can process IOCTL requests (see AX=4402h)
  812.   13    output until busy supported
  813.   11    driver supports OPEN/CLOSE calls
  814.    7    set (indicates device)
  815.    6    EOF on input
  816.    5    raw (binary) mode
  817.    4    device is special (uses INT 29)
  818.    3    clock device
  819.    2    NUL device
  820.    1    standard output
  821.    0    standard input
  822.  disk file
  823.   15    file is remote (DOS 3.0+)
  824.   14    don't set file date/time on closing (DOS 3.0+)
  825.   11    media not removable
  826.    8    (DOS 4 only) generate INT 24 if no disk space on write or read past
  827.       end of file
  828.    7    clear (indicates file)
  829.    6    file has not been written
  830.   5-0    drive number (0 = A:)
  831. --------D-214401-----------------------------
  832. INT 21 - DOS 2+ - IOCTL - SET DEVICE INFORMATION
  833.     AX = 4401h
  834.     BX = handle (must refer to character device)
  835.     DX = device information word (see #0720)
  836.         (DH must be zero)
  837. Return: CF clear if successful
  838.     CF set on error
  839.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  840. SeeAlso: AX=4400h,INT 2F/AX=122Bh
  841. --------D-214402-----------------------------
  842. INT 21 - DOS 2+ - IOCTL - READ FROM CHARACTER DEVICE CONTROL CHANNEL
  843.     AX = 4402h
  844.     BX = file handle referencing character device
  845.     CX = number of bytes to read
  846.     DS:DX -> buffer
  847. Return: CF clear if successful
  848.         AX = number of bytes actually read
  849.     CF set on error
  850.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  851. Note:    format of data is driver-specific (see below for some specific cases)
  852. SeeAlso: AX=4400h,AX=4403h,AX=4404h,INT 2F/AX=122Bh
  853. --------N-214402-----------------------------
  854. INT 21 - Network Driver Interface Specification (NDIS) 2.0.1 - PROTOCOL MANAGER
  855.     AX = 4402h
  856.     BX = file handle for device "PROTMAN$"
  857.     CX = 000Eh (size of request block)
  858.     DS:DX -> request block (see #0721,#0722,#0723,#0724,#0725,#0729,#0730)
  859. Return: CF clear if successful
  860.         AX = number of bytes actually read
  861.     CF set on error
  862.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  863. SeeAlso: AX=4402h"FTPSOFT"
  864.  
  865. Format of NDIS request block for GetProtocolManagerInfo:
  866. Offset    Size    Description    (Table 0721)
  867.  00h    WORD    01h
  868.  02h    WORD    returned status (see #0731)
  869.  04h    DWORD    returned pointer to structure representing parsed user config
  870.  08h    DWORD    unused
  871.  0Ch    WORD    returned BCD version of NDIS on which Protocol Manager is based
  872. SeeAlso: #0722,#0723,#0724,#0725,#0726,#0727,#0728,#0729,#0730
  873.  
  874. Format of NDIS request block for RegisterModule:
  875. Offset    Size    Description    (Table 0722)
  876.  00h    WORD    02h
  877.  02h    WORD    returned status (see #0731)
  878.  04h    DWORD    pointer to module's common characteristics table (see #0732)
  879.  08h    DWORD    pointer to list of modules to which the module is to be bound
  880.  0Ch    WORD    unused
  881. SeeAlso: #0721,#0723,#0724,#0725,#0726,#0727,#0728,#0729,#0730
  882.  
  883. Format of NDIS request block for BindAndStart:
  884. Offset    Size    Description    (Table 0723)
  885.  00h    WORD    03h
  886.  02h    WORD    returned status (see #0731)
  887.  04h    DWORD    caller's virtual address in FailingModules structure
  888.  08h    DWORD    unused
  889.  0Ch    WORD    unused
  890. SeeAlso: #0721,#0722,#0724,#0725,#0726,#0727,#0728,#0729,#0730
  891.  
  892. Format of NDIS request block for GetProtocolManagerLinkage:
  893. Offset    Size    Description    (Table 0724)
  894.  00h    WORD    04h
  895.  02h    WORD    returned status (see #0731)
  896.  04h    DWORD    returned dispatch point
  897.  08h    DWORD    unused
  898.  0Ch    WORD    returned protocol manager DS
  899. Note:    the dispatch point may be called as follows instead of using this IOCTL
  900.     STACK: WORD  protocol manager DS
  901.            DWORD pointer to request block
  902.     Return: AX = returned status
  903.         STACK popped
  904. SeeAlso: #0721,#0722,#0723,#0725,#0726,#0727,#0728,#0729,#0730
  905.  
  906. Format of NDIS request block for GetProtocolIniPath:
  907. Offset    Size    Description    (Table 0725)
  908.  00h    WORD    05h
  909.  02h    WORD    returned status (see #0731)
  910.  04h    DWORD    pointer to a buffer for the ASCIZ pathname of PROTOCOL.INI
  911.  08h    DWORD    unused
  912.  0Ch    WORD    buffer length
  913. SeeAlso: #0721,#0722,#0723,#0724,#0726,#0727,#0728,#0729,#0730
  914.  
  915. Format of NDIS request block for RegisterProtocolManagerInfo:
  916. Offset    Size    Description    (Table 0726)
  917.  00h    WORD    06h
  918.  02h    WORD    returned status (see #0731)
  919.  04h    DWORD    pointer to structure containing parsed user config file
  920.  08h    DWORD    unused
  921.  0Ch    WORD    length of structure
  922. SeeAlso: #0721,#0722,#0723,#0724,#0725,#0727,#0728,#0729,#0730
  923.  
  924. Format of NDIS request block for InitAndRegister:
  925. Offset    Size    Description    (Table 0727)
  926.  00h    WORD    07h
  927.  02h    WORD    returned status (see #0731)
  928.  04h    DWORD    unused
  929.  08h    DWORD    poitner to ASCIZ name of the module to be prebind initialized
  930.  0Ch    WORD    unused
  931. SeeAlso: #0721,#0722,#0723,#0724,#0725,#0726,#0728,#0729,#0730
  932.  
  933. Format of NDIS request block for UnbindAndStop:
  934. Offset    Size    Description    (Table 0728)
  935.  00h    WORD    08h
  936.  02h    WORD    returned status (see #0731)
  937.  04h    DWORD    failing modules as for BindAndStart
  938.  08h    DWORD    if not 0000h:0000h, pointer to ASCIZ name of module to unbind
  939.         if 0000h:0000h, terminate a set of previously dynamically
  940.           bound protocol modules
  941.  0Ch    WORD    unused
  942. SeeAlso: #0721,#0722,#0723,#0724,#0725,#0726,#0727,#0729,#0730
  943.  
  944. Format of NDIS request block for BindStatus:
  945. Offset    Size    Description    (Table 0729)
  946.  00h    WORD    09h
  947.  02h    WORD    returned status (see #0731)
  948.  04h    DWORD    must be 0000h:0000h
  949.         on return, points to root tree
  950.  08h    DWORD    0000h:0000h
  951.  0Ch    WORD    unused under DOS
  952. SeeAlso: #0721,#0722,#0723,#0724,#0725,#0726,#0727,#0728,#0730
  953.  
  954. Format of NDIS request block for RegisterStatus:
  955. Offset    Size    Description    (Table 0730)
  956.  00h    WORD    0Ah
  957.  02h    WORD    returned status (0000h, 0008h, 002Ch) (see #0731)
  958.  04h    DWORD    0000h:0000h
  959.  08h    DWORD    pointer to 16-byte ASCIZ module name
  960.  0Ch    WORD    0000h
  961. Note:    not supported by the 10NET v5.0 PROTMAN$ driver
  962. SeeAlso: #0721,#0722,#0723,#0724,#0725,#0726,#0727,#0728,#0729
  963.  
  964. (Table 0731)
  965. Values for NDIS status code:
  966.  0000h    success
  967.  0001h    wait for release--protocol has retained control of the data buffer
  968.  0002h    request queued
  969.  0003h    frame not recognized
  970.  0004h    frame rejected
  971.  0005h    frame should be forwarded
  972.  0006h    out of resource
  973.  0007h    invalid parameter
  974.  0008h    invalid function
  975.  0009h    not supported
  976.  000Ah    hardware error
  977.  000Bh    transmit error
  978.  000Ch    unrecognized destination
  979.  000Dh    buffer too small
  980.  0020h    already started
  981.  0021h    binding incomplete
  982.  0022h    driver not initialized
  983.  0023h    hardware not found
  984.  0024h    hardware failure
  985.  0025h    configuration failure
  986.  0026h    interrupt conflict
  987.  0027h    MAC incompatible
  988.  0028h    initialization failed
  989.  0029h    no binding
  990.  002Ah    network may be disconnected
  991.  002Bh    incompatible OS version
  992.  002Ch    already registered
  993.  002Dh    path not found
  994.  002Eh    insufficient memory
  995.  002Fh    info not found
  996.  00FFh    general failure
  997.  F000h-FFFFh reserved for vendor-specific codes, treated as general failure
  998.  
  999. Format of NDIS common characteristics table:
  1000. Offset    Size    Description    (Table 0732)
  1001.  00h    WORD    size of table in bytes
  1002.  02h    BYTE    NDIS major version
  1003.  03h    BYTE    NDIS minor version
  1004.  04h    WORD    reserved
  1005.  06h    BYTE    module major version
  1006.  07h    BYTE    module minor version
  1007.  08h    DWORD    module function flag bits
  1008.         bit 0: binding at upper boundary supported
  1009.         bit 1: binding at lower boundary supported
  1010.         bit 2: dynamically bound
  1011.         bits 3-31 reserved, must be 0
  1012.  0Ch 16 BYTEs    ASCIZ module name
  1013.  1Ch    BYTE    upper boundary protocol level (see #0733)
  1014.  1Dh    BYTE    upper boundary interface type
  1015.         for MACs: 1 = MAC
  1016.         for data links and transports: to be defined
  1017.         for session: 1 = NCB
  1018.         any level: 0 = private (ISV-defined)
  1019.  1Eh    BYTE    lower boundary protocol level (see #0733)
  1020.  1Fh    BYTE    lower boundary interface type
  1021.         same as offset 1Dh
  1022.  20h    WORD    module ID filled in by protocol manager
  1023.  22h    WORD    module DS
  1024.  24h    DWORD    system request entry point
  1025.  28h    DWORD    pointer to service-specific characteristics (see #0735,#0737)
  1026.         0000h:0000h if none
  1027.  2Ch    DWORD    pointer to service-specific status, or 0000h:0000h if none
  1028.           (see #0738)
  1029.  30h    DWORD    pointer to upper dispatch table (see #0734)
  1030.         0000h:0000h if none
  1031.  34h    DWORD    pointer to lower dispatch table (see #0734)
  1032.         0000h:0000h if none
  1033.  38h  2 DWORDs    reserved, must be 0
  1034. Note:    for compatibility with NDIS 1.x.x, a major version of 00h is
  1035.       interpreted as 01h
  1036.  
  1037. (Table 0733)
  1038. Values for NDIS boundary protocol level:
  1039.  00h    physical
  1040.  01h    Media Access Control
  1041.  02h    Data link
  1042.  03h    network
  1043.  04h    transport
  1044.  05h    session
  1045.  FFh    not specified
  1046.  
  1047. Format of NDIS dispatch table:
  1048. Offset    Size    Description    (Table 0734)
  1049.  00h    DWORD    -> common characteristics table (see #0732)
  1050.  04h  4 BYTEs    ???
  1051.  08h    DWORD    -> ??? function (called with 12 bytes of stack arguments)
  1052.  0Ch    DWORD    -> ??? function (called with 10 bytes of stack arguments)
  1053.  10h    DWORD    -> ??? function (called with 16 bytes of stack arguments)
  1054.  14h    DWORD    -> ??? function (called with 4 bytes of stack arguments)
  1055.  18h    DWORD    -> ??? function (called with 18 bytes of stack arguments)
  1056.  1Ch    DWORD    -> ??? function (called with 12 bytes of stack arguments)
  1057.  
  1058. Format of MAC Service-Specific Characteristics Table:
  1059. Offset    Size    Description    (Table 0735)
  1060.  00h    WORD    length of table in bytes
  1061.  02h 16 BYTEs    ASCIZ MAC type name, "802.3", "802.4", "802.5", "802.6", "DIX",
  1062.           "DIX+802.3", "APPLETALK", "ARCNET", "FDDI", "SDLC", "BSC",
  1063.           "HDLC", or "ISDN"
  1064.  12h    WORD    length of station addresses in bytes
  1065.  14h 16 BYTEs    permanent station address
  1066.  24h 16 BYTEs    current station address
  1067.  34h    DWORD    current functional adapter address (00000000h if none)
  1068.  38h    DWORD    pointer to multicast address list
  1069.  3Ch    DWORD    link speed in bits/sec
  1070.  40h    DWORD    service flags (see #0736)
  1071.  44h    WORD    maximum frame size which may be both sent and received
  1072.  46h    DWORD    total transmit buffer capacity in bytes
  1073.  4Ah    WORD    transmit buffer allocation block size in bytes
  1074.  4Ch    DWORD    total receive buffer capacity in bytes
  1075.  50h    WORD    receive buffer allocation block size in bytes
  1076.  52h  3 BYTEs    IEEE vendor code
  1077.  55h    BYTE    vendor adapter code
  1078.  56h    DWORD    pointer to ASCIZ vendor adapter description
  1079.  5Ah    WORD    IRQ used by adapter
  1080.  5Ch    WORD    transmit queue depth
  1081.  5Eh    WORD    maximum supported number of data blocks in buffer descriptors
  1082.  60h  N BYTEs    vendor-specific info
  1083. SeeAlso: #0737
  1084.  
  1085. Bitfields for service flags:
  1086. Bit(s)    Description    (Table 0736)
  1087.  0    supports broadcast
  1088.  1    supports multicast
  1089.  2    supports functional/group addressing
  1090.  3    supports promiscuous mode
  1091.  4    station address software settable
  1092.  5    statistics always current
  1093.  6    supports InitiateDiagnostics
  1094.  7    supports loopback
  1095.  8    MAC does primarily ReceiveChain indications instead of ReceiveLookahead
  1096.     indications
  1097.  9    supports IBM source routing
  1098.  10    supports MAC reset
  1099.  11    supports Open/Close adapter
  1100.  12    supports interrupt request
  1101.  13    supports source routing bridge
  1102.  14    supports GDT virtual addresses (OS/2 version)
  1103.  15    multiple TransferDatas allowed durign a single indication
  1104.  16    MAC normally sets FrameSize = 0 in ReceiveLookahead
  1105.  17-31    reserved, must be 0
  1106.  
  1107. Format of NetBIOS Service-Specific Characteristics Table:
  1108. Offset    Size    Description    (Table 0737)
  1109.  00h    WORD    length of table in bytes
  1110.  02h 16 BYTEs    ASCIZ type name of NetBIOS module
  1111.  12h    WORD    NetBIOS module code
  1112.  14h  N BYTEs    vendor-specific info
  1113. SeeAlso: #0735
  1114.  
  1115. Format of MAC Service-Specific Status Table:
  1116. Offset    Size    Description    (Table 0738)
  1117.  00h    WORD    length of table in bytes
  1118.  02h    DWORD    seconds since 0:00 1/1/70 when diagnostics last run
  1119.         (FFFFFFFFh = never)
  1120.  06h    DWORD    MAC status bits (see #0739)
  1121.  0Ah    WORD    current packet filter flags (see #0740)
  1122.  0Ch    DWORD    pointer to media-specific status table or 0000h:0000h
  1123.  10h    DWORD    seconds past 0:00 1/1/70 of last ClearStatistics
  1124.  14h    DWORD    total frames received (FFFFFFFFh = not counted)
  1125.  18h    DWORD    frames with CRC error (FFFFFFFFh = not counted)
  1126.  1Ch    DWORD    total bytes received (FFFFFFFFh = not counted)
  1127.  20h    DWORD    frames discarded--no buffer space (FFFFFFFFh = not counted)
  1128.  24h    DWORD    multicast frames received (FFFFFFFFh = not counted)
  1129.  28h    DWORD    broadcast frames received (FFFFFFFFh = not counted)
  1130.  2Ch    DWORD    frames with errors (FFFFFFFFh = not counted)
  1131.  30h    DWORD    overly large frames (FFFFFFFFh = not counted)
  1132.  34h    DWORD    frames less than minimum size (FFFFFFFFh = not counted)
  1133.  38h    DWORD    multicast bytes received (FFFFFFFFh = not counted)
  1134.  3Ch    DWORD    broadcast bytes received (FFFFFFFFh = not counted)
  1135.  40h    DWORD    frames discarded--hardware error (FFFFFFFFh = not counted)
  1136.  44h    DWORD    total frames transmitted (FFFFFFFFh = not counted)
  1137.  48h    DWORD    total bytes transmitted (FFFFFFFFh = not counted)
  1138.  4Ch    DWORD    multicast frames transmitted (FFFFFFFFh = not counted)
  1139.  50h    DWORD    broadcast frames transmitted (FFFFFFFFh = not counted)
  1140.  54h    DWORD    broadcast bytes transmitted (FFFFFFFFh = not counted)
  1141.  58h    DWORD    multicast bytes transmitted (FFFFFFFFh = not counted)
  1142.  5Ch    DWORD    frames not transmitted--timeout (FFFFFFFFh = not counted)
  1143.  60h    DWORD    frames not transmitted--hardware error (FFFFFFFFh = not countd)
  1144.  64h  N BYTEs    vendor-specific info
  1145.  
  1146. Bitfields for MAC status bits:
  1147. Bit(s)    Description    (Table 0739)
  1148.  0-2    operational status
  1149.     000 hardware not installed
  1150.     001 hardware failed startup diagnostics
  1151.     010 hardware configuration problem
  1152.     011 hardware fault
  1153.     100 operating marginally due to soft faults
  1154.     101 reserved
  1155.     110 reserved
  1156.     111 hardware fully operational
  1157.  3    MAC bound
  1158.  4    MAC open
  1159.  5    diagnostics in progress
  1160.  6-31    reserved
  1161.  
  1162. Bitfields for packet filter flags:
  1163. Bit(s)    Description    (Table 0740)
  1164.  0    directed/multicast or group/functional
  1165.  1    broadcast
  1166.  2    promiscuous
  1167.  3    all source routing
  1168.  4-15    reserved, must be zero
  1169. --------I-214402-----------------------------
  1170. INT 21 U - IBM SYSTEM 36/38 WORKSTATION EMULATION - VDI.SYS - GET ???
  1171.     AX = 4402h
  1172.     BX = handle for character device "GDMS"
  1173.     CX = number of bytes to read (>= 4)
  1174.     DS:DX -> buffer (see #0741)
  1175. Return: CF set on error
  1176.         AX = error code (see #0960 at AH=59h)
  1177.     CF clear if successful
  1178.         AX = number of bytes read
  1179.  
  1180. Format of System 36/38 emulator returned data:
  1181. Offset    Size    Description    (Table 0741)
  1182.  00h  4 BYTEs    ???
  1183.  04h    DWORD    pointer to ???
  1184.  08h  4 BYTEs    ???
  1185. --------m-214402-----------------------------
  1186. INT 21 U - LASTBYTE.SYS v1.19 - IOCTL - GET ??? TABLE
  1187.     AX = 4402h
  1188.     BX = handle for device "LA$TBYTE"
  1189.     CX = 0004h
  1190.     DS:DX -> DWORD to hold address of 39-byte table of ???
  1191. Return: CF set on error
  1192.         AX = error code (see #0960 at AH=59h)
  1193.     CF clear if successful
  1194.         AX = number of bytes read
  1195. Program: LASTBYTE.SYS is part of the shareware "The Last Byte" memory
  1196.       management package by Key Software Products
  1197. SeeAlso: AX=4402h"HIGHUMM"
  1198. --------m-214402-----------------------------
  1199. INT 21 - HIGHUMM.SYS v1.17+ - IOCTL - GET API ADDRESS
  1200.     AX = 4402h
  1201.     BX = handle for device "KSP$UMM"
  1202.     CX = 0004h
  1203.     DS:DX -> DWORD to hold entry point (see #0742)
  1204. Return: CF set on error
  1205.         AX = error code (see #0960 at AH=59h)
  1206.     CF clear if successful
  1207.         AX = number of bytes read
  1208. Program: HIGHUMM.SYS is part of the shareware "The Last Byte" memory management
  1209.       package by Key Software Products
  1210. SeeAlso: AX=4402h"LASTBYTE"
  1211.  
  1212. (Table 0742)
  1213. Call HIGHUMM.SYS entry point with:
  1214.     AH = 00h allocate UMB (same as XMS function 10h) (see INT 2F/AX=4310h)
  1215.         DX = size in paragraphs
  1216.         Return: BX = segment number (if successful)
  1217.             DX = size of requested block/size of largest block
  1218.     AH = 01h deallocate UMB (same as XMS func 11h) (see INT 2F/AX=4310h)
  1219.         DX = segment number of UMB
  1220.     AH = 02h request a bank-switched memory block
  1221.         DX = size in paragraphs
  1222.         Return: BX = segment number (if successful)
  1223.             DX = size of requested block/size of largest block
  1224.     AH = 03h release a bank-switched memory block
  1225.         DX = segment number
  1226.     AH = 04h transfer data to/from high memory
  1227.         DS:SI -> source
  1228.         ES:DI -> destination
  1229.         CX = length in bytes
  1230.         Note: enables bank-switched memory, does the copy, then disables
  1231.         bank-switched memory
  1232.     AH = 05h get a word from bank-switched memory
  1233.         ES:DI -> word to read
  1234.         Return: DX = word
  1235.     AH = 06h put a word to bank-switched memory
  1236.         ES:DI -> word to write
  1237.         DX = word
  1238.     AH = 07h put a byte to bank-switched memory
  1239.         ES:DI -> byte to write
  1240.         DL = byte
  1241.     AH = 08h enable bank-switched memory
  1242.         DS:SI -> 6-byte status save area
  1243.     AH = 09h disable bank-switched memory
  1244.         DS:SI -> 6-byte save area from enable call (AH=08h)
  1245.     AH = 0Ah assign name to UMB or high bank-switched block
  1246.         DX = segment number
  1247.         DS:SI -> 8-byte blank-padded name
  1248.     AH = 0Bh locate UMB block by name
  1249.         DS:SI -> 8-byte blank-padded name
  1250.         Return: BX = segment number (if successful)
  1251.             DX = size of block
  1252.     AH = 0Ch locate bank-switched block by name
  1253.         DS:SI -> 8-byte blank-padded name
  1254.         Return: BX = segment number (if successful)
  1255.             DX = size of block
  1256. Return: AX = status code
  1257.         0001h successful
  1258.         0000h failed
  1259.         BL = error code
  1260.             80h not implemented
  1261.             B0h insufficient memory, smaller block available
  1262.             B1h insufficient memory, no blocks available
  1263.             B2h invalid segment number
  1264. Note:    only functions 00h and 01h are always available; the remaining
  1265.       functions are only enabled if the proper commandline switch is given
  1266. --------c-214402-----------------------------
  1267. INT 21 - SMARTDRV.SYS v3.x only - IOCTL - GET CACHE STATUS
  1268.     AX = 4402h
  1269.     BX = file handle for device "SMARTAAR"
  1270.     CX = number of bytes to read (min 28h)
  1271.     DS:DX -> buffer for status record (see #0743)
  1272. Return: CF clear if successful
  1273.         AX = number of bytes actually read
  1274.     CF set on error
  1275.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  1276. Note:    NCache2 (from the Norton Utilities v8.0) attempts to support this
  1277.       interface, but does not do so correctly, often hanging the system;
  1278.       one should use the SmartDrive v4.x or NCache private interfaces
  1279.       (see INT 2F/AX=4A10h/BX=0000h,INT 2F/AX=FE00h/DI=4E55h)
  1280. SeeAlso: AX=4403h"SMARTDRV",INT 2F/AX=4A10h/BX=0000h
  1281.  
  1282. Format of SMARTDRV status record:
  1283. Offset    Size    Description    (Table 0743)
  1284.  00h    BYTE    write-through flag (always 01h)
  1285.  01h    BYTE    writes should be buffered (always 00h)
  1286.  02h    BYTE    cache enabled if 01h
  1287.  03h    BYTE    driver type (01h extended memory, 02h expanded)
  1288.  04h    WORD    clock ticks between cache flushes (currently unused)
  1289.  06h    BYTE    cache contains locked tracks if nonzero
  1290.  07h    BYTE    flush cache on INT 19 reboot if nonzero
  1291.  08h    BYTE    cache full track writes if nonzero
  1292.  09h    BYTE    double buffering (for VDS) state (00h off, 01h on, 02h dynamic)
  1293.  0Ah    DWORD    original INT 13 vector
  1294.  0Eh    BYTE    minor version number
  1295.  0Fh    BYTE    major version number
  1296.  10h    WORD    unused
  1297.  12h    WORD    sectors read            \
  1298.  14h    WORD    sectors already in cache     > may be scaled rather than
  1299.  16h    WORD    sectors already in track buffer /  absolute counts
  1300.  18h    BYTE    cache hit rate in percent
  1301.  19h    BYTE    track buffer hit rate in percent
  1302.  1Ah    WORD    total tracks in cache
  1303.  1Ch    WORD    number of tracks in use
  1304.  1Eh    WORD    number of locked tracks
  1305.  20h    WORD    number of dirty tracks
  1306.  22h    WORD    current cache size in 16K pages
  1307.  24h    WORD    original (maximum) cache size in 16K pages
  1308.  26h    WORD    minimum cache size in 16K pages
  1309.  28h    DWORD    pointer to byte flag to increment for locking cache contents
  1310. --------d-214402-----------------------------
  1311. INT 21 - CD-ROM device driver - IOCTL INPUT
  1312.     AX = 4402h
  1313.     BX = file handle referencing character device for CD-ROM driver
  1314.     CX = number of bytes to read
  1315.     DS:DX -> control block (see #0745)
  1316. Return: CF clear if successful
  1317.         AX = number of bytes actually read
  1318.     CF set on error
  1319.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  1320. Note:    the data returned depends on the first byte of the control block; the
  1321.       remainder of the control block is filled by the driver
  1322. SeeAlso: AX=4403h"CD-ROM",INT 2F/AX=0802h
  1323.  
  1324. (Table 0744)
  1325. Values for CD-ROM data being requested:
  1326.  00h    device driver header address
  1327.  01h    drive head location
  1328.  02h    reserved
  1329.  03h    error statistics
  1330.  04h    audio channel info
  1331.  05h    raw drive bytes (uninterpreted and device-specific)
  1332.  06h    device status
  1333.  07h    sector size
  1334.  08h    volume size
  1335.  09h    media change status
  1336.  0Ah    audio disk info
  1337.  0Bh    audio track info
  1338.  0Ch    audio Q-Channel info
  1339.  0Dh    audio sub-channel info
  1340.  0Eh    UPC code
  1341.  0Fh    audio status info
  1342.  
  1343. Format of CD-ROM control block:
  1344. Offset    Size    Description    (Table 0745)
  1345.  00h    BYTE    data being requested (see #0744)
  1346. ---function 00h---
  1347.  01h    DWORD    device driver header address (see also AH=52h)
  1348. ---function 01h---
  1349.  01h    BYTE    addressing mode
  1350.         00h HSG
  1351.         01h Red Book
  1352.  02h    DWORD    current location of drive's head
  1353.         logical sector number in HSG mode
  1354.         frame/second/minute/unused in Red Book mode
  1355.         (HSG sector = minute * 4500 + second * 75 + frame - 150)
  1356. ---function 03h---
  1357.  01h  N BYTEs    undefined as of 5 Aug 88 specification
  1358. ---function 04h---
  1359.  01h    BYTE    input channel (0-3) for output channel 0
  1360.  02h    BYTE    volume for output channel 0
  1361.  03h    BYTE    input channel (0-3) for output channel 1
  1362.  04h    BYTE    volume for output channel 1
  1363.  05h    BYTE    input channel (0-3) for output channel 2
  1364.  06h    BYTE    volume for output channel 2
  1365.  07h    BYTE    input channel (0-3) for output channel 3
  1366.  08h    BYTE    volume for output channel 3
  1367. Notes:    output channels 0 and 1 are left and right, 2 and 3 are left prime and
  1368.       right prime; a volume of 00h is off
  1369.     the default setting is for each input channel to be assigned to the
  1370.       same-numbered output channel at full (FFh) volume
  1371. ---function 05h---
  1372.  01h    BYTE    number of bytes read
  1373.  02h 128 BYTEs    buffer for drive bytes
  1374. ---function 06h---
  1375.  01h    DWORD    device parameters (see #0746)
  1376. ---function 07h---
  1377.  01h    BYTE    read mode
  1378.         00h cooked
  1379.         01h raw
  1380.  02h    WORD    sector size in bytes
  1381. ---function 08h---
  1382.  01h    DWORD    volume size in sectors
  1383. ---function 09h---
  1384.  01h    BYTE    media change status
  1385.         00h don't know
  1386.         01h media unchanged
  1387.         FFh media has been changed
  1388. ---function 0Ah---
  1389.  01h    BYTE    lowest audio track number
  1390.  02h    BYTE    highest audio track number
  1391.  03h    DWORD    start address of lead-out track (Red Book format)
  1392. --function 0Bh---
  1393.  01h    BYTE    track number (set by caller)
  1394.  02h    DWORD    starting point of track (Red Book format)
  1395.  06h    BYTE    track control info
  1396.         bits 15,14,12: track type (notice: bits not contiguous!)
  1397.             000 two audio channels, no pre-emphasis
  1398.             001 two audio channels with pre-emphasis
  1399.             010 data track
  1400.             100 four audio channels, no pre-emphasis
  1401.             101 four audio channels with pre-emphasis
  1402.             other reserved
  1403.         bit 13: digital copy permitted
  1404. ---function 0Ch---
  1405.  01h    BYTE    CONTROL and ADR byte (as received from drive)
  1406.  02h    BYTE    track number
  1407.  03h    BYTE    point or index
  1408.  04h    BYTE    minute    \
  1409.  05h    BYTE    second     > running time within track
  1410.  06h    BYTE    frame    /
  1411.  07h    BYTE    zero
  1412.  08h    BYTE    "AMIN" or "PMIN"     \
  1413.  09h    BYTE    "ASEC" or "PSEC"      > running time on disk
  1414.  0Ah    BYTE    "AFRAME" or "PFRAME" /
  1415. ---function 0Dh---
  1416.  01h    DWORD    starting frame address (Red Book format)
  1417.  05h    DWORD    transfer address
  1418.  09h    DWORD    number of sectors to read
  1419. Note:    copies 96 bytes of sub-channel info per sector into buffer
  1420. ---function 0Eh---
  1421.  01h    BYTE    CONTROL and ADR byte
  1422.  02h  7 BYTEs    UPC/EAN code (13 BCD digits,low-order nybble of last byte is 0)
  1423.  09h    BYTE    zero
  1424.  0Ah    BYTE    "AFRAME"
  1425. ---function 0Fh---
  1426.  ??? documentation not yet available
  1427.  01h    WORD    pause status (0000h not paused, 0001h paused)
  1428.  03h    DWORD    audio play start address
  1429.  07h    DWORD    ??? audio play length or end address
  1430.  
  1431. Bitfields for CD-ROM device parameters:
  1432. Bit(s)    Description    (Table 0746)
  1433.  0    door open
  1434.  1    door unlocked
  1435.  2    supports raw reading in addition to cooked
  1436.  3    writable
  1437.  4    can play audio/video tracks
  1438.  5    supports interleaving
  1439.  6    reserved
  1440.  7    supports prefetch requests
  1441.  8    supports audio channel control
  1442.  9    supports Red Book addressing in addition to HSG
  1443.  10    audio is playing
  1444.  11    no disk in drive
  1445.  12    supports R-W subchannels
  1446. --------m-214402-----------------------------
  1447. INT 21 - Quarterdeck - QEMM-386 v5+ - GET API ENTRY POINT
  1448.     AX = 4402h
  1449.     BX = file handle for device "QEMM386$"
  1450.     CX = 0004h
  1451.     DS:DX -> DWORD buffer for API entry point
  1452. Return: CF clear if successful
  1453.         buffer filled (see INT 67/AH=3Fh for entry point parameters)
  1454.     CF set on error
  1455.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  1456. Note:    Quarterdeck recently (June 1993) documented this function, but the
  1457.       documentation incorrectly states that it is only available for
  1458.       QEMM 6+
  1459. SeeAlso: AX=4402h"HOOKROM",INT 2F/AX=D201h/BX=5145h,INT 67/AH=3Fh
  1460. --------Q-214402-----------------------------
  1461. INT 21 U - Quarterdeck - HOOKROM.SYS - GET HOOKED VECTOR TABLE
  1462.     AX = 4402h
  1463.     BX = file handle for device "HOOKROM$"
  1464.     CX = 0004h
  1465.     DS:DX -> DWORD buffer for address of hooked vector table (see #0747)
  1466. Return: CF clear if successful
  1467.         DS:DX buffer filled
  1468.     CF set on error
  1469.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  1470. SeeAlso: AX=4402h/SF=01h
  1471.  
  1472. Format of HOOKROM.SYS hooked vector table entry:
  1473. Offset    Size    Description    (Table 0747)
  1474.  00h  5 BYTEs    FAR jump to actual interrupt handler
  1475.         (end of table if first byte is not EAh)
  1476.  05h    BYTE    interrupt vector number
  1477. --------d-214402-----------------------------
  1478. INT 21 - Advanced SCSI Programming Interface (ASPI) - INTERFACE
  1479.     AX = 4402h
  1480.     BX = file handle for device "SCSIMGR$"
  1481.     CX = 0004h or 0005h (see notes)
  1482.     DS:DX -> buffer for result (see #0748), set to zeros before call
  1483. Return: CF clear if successful
  1484.         AX = 0004h or 0005h (see notes)
  1485.     CF set on error
  1486.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  1487. Note:    the variant of the call requesting five bytes is an UNDOCUMENTED
  1488.       extension supported by Adaptec's ASPI2DOS.SYS, ASPI4DOS.SYS, and
  1489.       ASPI7DOS.SYS; if made of a host manager which does not support the
  1490.       variant, only four bytes will be returned.  If the variant is
  1491.       supported, Adaptec's WINASPI.DLL assumes that the host manager is
  1492.       an "advanced" one which operates in either real or protected mode
  1493.       (and thus does not require a DPMI INT 31/AX=0301h call to be invoked
  1494.       from protected mode).     Support of the five-byte variant also appears
  1495.       to imply that an advanced ASPI host manager uses no temporary
  1496.       storage space except the SRB (see #0750) and the stack, and that it
  1497.       is fully reentrant.
  1498.     if called with a standard request for four bytes, even Adaptec's
  1499.       advanced drivers return only the requested four bytes containing the
  1500.       ASPI entry point address
  1501.     the function address is called with the address of a SCSI Request
  1502.       Block (see #0750) on the stack and the caller must clean up the
  1503.       stack
  1504. SeeAlso: AX=440Ch"ASPITAPE",INT 11/AH=FFh"WD7000"
  1505.  
  1506. Format of ASPI IOCTL result:
  1507. Offset    Size    Description    (Table 0748)
  1508.  00h    DWORD    function address
  1509.  04h    BYTE    number of SCSI host adapters supported by host manager
  1510.  
  1511. (Table 0749)
  1512. Values for ASPI request number:
  1513.  00h    "HA_INQ"    host adapter inquiry
  1514.  01h    "GET_TYPE"    get device type
  1515.  02h    "EXEC_SIO"    execute SCSI I/O
  1516.  03h    "ABORT_SRB"    abort SRB
  1517.  04h    "RESET_DEV"    reset SCSI device
  1518.  05h    "SET_HAPRMS"    set host adapter parameters
  1519.  06h    get disk drive information
  1520.  
  1521. Format of SCSI Request Block (64 bytes):
  1522. Offset    Size    Description    (Table 0750)
  1523.  00h    BYTE    request number (see #0749)
  1524.  01h    BYTE    request status (see #0751)
  1525.  02h    BYTE    host adapter ID
  1526.  03h    BYTE    request flags (see #0752)
  1527.  04h    DWORD    reserved
  1528. ---request 00h---
  1529.  08h    BYTE    (ret) number of host adapters
  1530.  09h    BYTE    (ret) target adapter ID
  1531.  0Ah 16 BYTEs    (ret) SCSI manager ID
  1532.  1Ah 16 BYTEs    (ret) host adapter ID
  1533.  2Ah 16 BYTEs    (ret) host adapter-unique parameters
  1534. ---request 01h---
  1535.  08h    BYTE    target ID
  1536.  09h    BYTE    logical unit number
  1537.  0Ah    BYTE    (ret) device type (see #0755)
  1538. ---request 02h---
  1539.  08h    BYTE    target ID
  1540.  09h    BYTE    logical unit number
  1541.  0Ah    DWORD    data allocation length
  1542.  0Eh    BYTE    sense allocation length
  1543.  0Fh    DWORD    data buffer pointer
  1544.  13h    DWORD    next request pointer (for linking)
  1545.  17h    BYTE    CDB length
  1546.  18h    BYTE    (ret) host adapter status (see #0750)
  1547.  19h    BYTE    (ret) target status (see #0754)
  1548.  1Ah    DWORD    post routine address
  1549.  1Eh    WORD    real mode Post DS
  1550.  20h    DWORD    SRB pointer
  1551.  24h    WORD    reserved
  1552.  26h    DWORD    SRB physical address
  1553.  2Ah 22 BYTEs    SCSIMGR$ workspace
  1554.  40h  N BYTEs    CCB, including sense data (20-24 bytes)
  1555. ---request 03h---
  1556.  08h    DWORD    address of SRB to abort
  1557. ---request 04h---
  1558.  08h    BYTE    target ID
  1559.  09h    BYTE    logical unit number
  1560.  0Ah 14 BYTEs    reserved
  1561.  18h    BYTE    (ret) host adapter status (see #0753)
  1562.  19h    BYTE    (ret) target status (see #0754)
  1563.  1Ah    DWORD    post routine address
  1564.  1Eh 34 BYTEs    workspace
  1565. ---request 05h---
  1566.  08h 16 BYTEs    host adapter-unique parameters
  1567. ---request 06h---
  1568.  08h    BYTE    target ID
  1569.  09h    BYTE    logical unit number
  1570.  0Ah    BYTE    disk drive flags (see #0756)
  1571.  0Bh    BYTE    INT 13h drive number
  1572.  0Ch    BYTE    preferred head number translation
  1573.  0Dh    BYTE    preferred sector size translation
  1574.  0Eh 10 BYTEs    reserved
  1575. SeeAlso: #0757
  1576.  
  1577. (Table 0751)
  1578. Values for ASPI request status:
  1579.  00h    not done yet
  1580.  01h    completed successfully
  1581.  02h    aborted by host
  1582.  04h    SCSI I/O error
  1583.  80h    invalid
  1584.  81h    no adapter
  1585.  82h    no device attached
  1586.  else    status
  1587.  
  1588. Bitfields for ASPI request flags:
  1589. Bit(s)    Description    (Table 0752)
  1590.  0    posting enabled
  1591.  1    linking enabled
  1592.  2    direction
  1593.  3    transfer from SCSI target to host
  1594.  4    transfer from host to SCSI target
  1595. Note:    no data is transferred if both bits 3 and 4 are set
  1596.  
  1597. (Table 0753)
  1598. Values for host adapter status:
  1599.  00h    no error detected
  1600.  11h    select timeout
  1601.  12h    data overrun
  1602.  13h    bus error
  1603.  14h    bus failure
  1604.  
  1605. (Table 0754)
  1606. Values for target status:
  1607.  00h    no status
  1608.  02h    sense data stored in SRB
  1609.  08h    target busy
  1610.  18h    reservation error
  1611.  
  1612. (Table 0755)
  1613. Values for device type:
  1614.  00h    disk drive
  1615.  01h    tape drive (streamer)
  1616.  02h    printer
  1617.  03h    processor
  1618.  04h    WORM drive
  1619.  05h    CD-ROM drive
  1620.  06h    scanner
  1621.  07h    optical drive
  1622.  08h    autochanger
  1623.  09h    communications device
  1624.  
  1625. (Table 0756)
  1626. Values for disk drive flags:
  1627.  00h    no INT 13 access
  1628.  01h    INT 13 with DOS access
  1629.  02h    INT 13 without DOS access
  1630.  03h    invalid flags
  1631.  
  1632. Format of CCB:
  1633. Offset    Size    Description    (Table 0757)
  1634.  00h    BYTE    command code (see #0758)
  1635.  01h    BYTE    flags
  1636.         bits 4-0: vary by function
  1637.         bits 7-5: logical unit number
  1638.  02h    BYTE    "adr_1"
  1639.  03h    BYTE    "adr_0"
  1640.  04h    BYTE    length
  1641.  05h    BYTE    control
  1642.     ...
  1643.  06h/0Ah 14 BYTEs buffer for sense data (see #0759)
  1644. SeeAlso: #0750
  1645.  
  1646. (Table 0758)
  1647. Values for CCB command code:
  1648.  00h    test unit ready
  1649.  01h    rewind
  1650.  03h    request sense data
  1651.  05h    get block size limits
  1652.  08h    Group 0 read
  1653.  0Ah    Group 0 write
  1654.  10h    write file marks
  1655.  11h    SCSI Space (set position?)
  1656.  12h    SCSI Inquire
  1657.  15h    set mode information
  1658.  16h    reserve SCSI device
  1659.  17h    release SCSI device
  1660.  19h    erase
  1661.  1Ah    request mode information
  1662.  1Bh    load/unload media
  1663.  1Dh    request target self-check
  1664.  24h    set window parameters
  1665.  25h    get window parameters
  1666.  28h    Group 1 read
  1667.  2Ah    Group 1 write
  1668.  31h    document feeder control
  1669.  34h    get scan data status
  1670. ---vendor-specific commands---
  1671.  D3h    get document feeder status
  1672.  D4h    set document feeder mode
  1673.  
  1674. Format of sense data:
  1675. Offset    Size    Description    (Table 0759)
  1676.  00h    BYTE    error code (bit 7 set if valid)
  1677.  01h    BYTE    segment number
  1678.  02h    BYTE    sense key
  1679.         bit 6: EOM
  1680.         bit 5: ILI
  1681.         bits 0-3: sense key (see #0760)
  1682.  03h  4 BYTEs    information bytes
  1683.  07h    BYTE    additional sense length (0Ah)
  1684.  08h  4 BYTEs    command-specific information
  1685.  0Ch    BYTE    additional sense code
  1686.  0Dh    BYTE    additional sense code qualifier
  1687.  0Eh    BYTE    field replaceable unit code
  1688.  0Fh  3 BYTEs    sense key specific bytes
  1689.  
  1690. (Table 0760)
  1691. Values for sense key:
  1692.  00h    no sense data
  1693.  02h    SCSI unit not ready
  1694.  03h    media error
  1695.  04h    unrecoverable hardware error
  1696.  05h    illegal parameter in CDB
  1697.  06h    target has been reset
  1698.  0Bh    target aborted command
  1699. --------m-214402-----------------------------
  1700. INT 21 U - Qualitas 386MAX v6.00+ - IOCTL INPUT - GET STATE
  1701.     AX = 4402h
  1702.     BX = file handle for device "386MAX$$"
  1703.     CX = number of bytes to read
  1704.     DS:DX -> BYTE 03h followed by 386MAX state buffer (see #0761)
  1705. Return: CF clear if successful
  1706.         buffer at DS:DX+1 filled
  1707.         AX = number of bytes actually copied
  1708.     CF set on error
  1709.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  1710. Notes:    if the value given in CX is less than the size of the state record
  1711.       (5Ah for v6.01, 66h for v7.00), only a partial state record will be
  1712.       returned
  1713.     the state is 40h bytes for 386MAX (actually ASTEMM) v2.20 ("386MAX$$"
  1714.       did not exist yet, use "QMMXXXX0" and then "EMMXXXX0" instead) and
  1715.       56h bytes for v5.11.
  1716.     to invoke 386MAX API functions, push DX onto the stack, load DX with
  1717.       the word at offset 25h in the returned state, load all other
  1718.       registers as needed for the desired function, and execute an
  1719.       OUT DX,AL or OUT DX,AX; DX will be set to the pushed value on return
  1720.       if it is not otherwise modified by the API function.    For safety,
  1721.       in case a function is not supported or 386MAX is not present, SP
  1722.       should be saved and restored around the API call.
  1723.     Windows 3.1 Standard mode, LAN Manager, and Windows for Workgroups all
  1724.       use the 386MAX API; LAN Manager and Windows for Workgroups reportedly
  1725.       make some calls incorrectly
  1726. SeeAlso: AX=4403h/SF=03h"386MAX",INT 67/AH=3Fh
  1727.  
  1728. Format of 386MAX v6.01+ state:
  1729. Offset    Size    Description    (Table 0761)
  1730.  -1    BYTE    (call) 03h
  1731.  00h  6 BYTEs    signature "386MAX"
  1732.  06h  4 BYTEs    version string "N;NN" or "N.NN" (i.e. "6;01" for v6.01)
  1733.         (';' by default; apparently changed to a period when 386MAX
  1734.         has linked high RAM into DOS's memory chain)
  1735.  0Ah    WORD    segment of low-memory portion of 386MAX.SYS
  1736.  0Ch  2 BYTEs    ???
  1737.  0Eh    WORD    segment of ??? memory block or 0000h
  1738.  10h    WORD    bit flags 1 (see #0762)
  1739.  12h    WORD    starting address of video memory in KB
  1740.  14h  2 BYTEs    ???
  1741.  16h    WORD    total high DOS memory in KB
  1742.  18h  2 BYTEs    ???
  1743.  1Ah    WORD    available shared memory in KB
  1744.  1Ch    WORD    KBytes extended memory used by 386MAX
  1745.  1Eh  2 BYTEs    ???
  1746.  20h    WORD    total extended memory in KB
  1747.  22h    WORD    IO port to write (OUT DX,AL) to invoke 386MAX INT 15 functions
  1748.  24h    WORD    IO port to write (OUT DX,AL) to invoke 386MAX API functions
  1749.           (see #0775)
  1750.  26h    WORD    ??? (depends on DOS version)
  1751.  28h    WORD    size of ??? in paragraphs
  1752.  2Ah    DWORD    machine type (see #0770)
  1753.  2Eh    DWORD    -> first DOS memory control block
  1754.  32h    WORD    system configuration flags (see #0763)
  1755.  34h    WORD    debugging flags 1 (see #0764)
  1756.  36h    WORD    debugging flags 2 (see #0765)
  1757.  38h  2 BYTEs    ???
  1758.  3Ah    WORD    segment of first MCB in high memory chain
  1759.  3Ch    WORD    feature flags 1 (see #0767)
  1760.  3Eh    WORD    feature flags 2 (see #0768)
  1761.  40h    WORD    feature flags 3 (see #0769)
  1762.  42h    WORD    segment of first 386MAX control block??? (see #0771)
  1763.  44h    WORD    amount of memory to report available on INT 15/AH=88h
  1764.  46h  4 BYTEs    ???
  1765.  4Ah    WORD    number of K at start of address space swapped with fast
  1766.           extended memory (SWAP= parameter)
  1767.  4Ch  2 BYTEs    ???
  1768.  4Eh    WORD    segment address of ???
  1769.  50h    WORD    debugging flags 3 (see #0766)
  1770.  52h    DWORD    old INT 21h
  1771.  56h    DWORD    pointer to 386MAX's EMS (INT 67h) handler
  1772. ---386MAX v7.00---
  1773.  5Ah    DWORD    KB of extended memory managed by 386MAX
  1774.  5Eh    DWORD    bytes of extended memory (EXT= parameter)
  1775.  62h  4 BYTEs    ???
  1776.  
  1777. Bitfields for 386MAX bit flags 1:
  1778. Bit(s)    Description    (Table 0762)
  1779.  1    ???
  1780.  2    allow A20 to be enabled/disabled???
  1781.  3    ??? (cleared by calling INT 67 functions or starting MSWindows)
  1782.  4    high RAM present???
  1783.  5    386MAX in AUTO mode
  1784.  6    386MAX enabled
  1785.  7    386MAX is providing EMS services
  1786.  8    ??? (affects API function 08h)
  1787.  9    A20 gate closed (A20 disabled) (see INT 15/AX=2402h)
  1788.  10    Weitek support enabled
  1789.  11    ???
  1790.  12    ROMs not shadowed???
  1791.  13    QPMS has been used
  1792.  14    ???
  1793.  15    ???
  1794.  
  1795. Bitfields for 386MAX system configuration flags:
  1796. Bit(s)    Description    (Table 0763)
  1797.  1    ROM compressed???
  1798.  3    ???
  1799.  5    386MAX loaded into high memory
  1800.  6    Microchannel bus
  1801.  7    Weitek math coprocessor detected
  1802.  9    ??? (also generates INT 01 on ??? and INT 03 on ???)
  1803.  11    PC/XT (thus only single 8259 interrupt controller present, DMA only
  1804.         in 1st megabyte, etc)
  1805.  13    LMLTOP= specified
  1806.  14    enable A20 control???
  1807.  15    ???
  1808.  
  1809. Bitfields for 386MAX debugging flags 1:
  1810. Bit(s)    Description    (Table 0764)
  1811.  0    DEBUG=LED
  1812.  1    DEBUG=X67
  1813.  2    DEBUG=INV
  1814.  3    DEBUG=EMSPTED
  1815.  4    DEBUG=JMP
  1816.  5    DEBUG=CALL
  1817.  6    DEBUG=HLT
  1818.  7    DEBUG=PMR
  1819.  8    DEBUG=CR3
  1820.  9    DEBUG=CAPS or DEBUG=INT
  1821.  10    DEBUG=RC
  1822.  11    DEBUG=ROM
  1823.  12    DEBUG=XM
  1824.  13    DEBUG=SOR
  1825.  14    DEBUG=XR
  1826.  15    DEBUG=EMSERR (generate INT 01 on returning error from EMS call)
  1827.  
  1828. Bitfields for 386MAX debugging flags 2:
  1829. Bit(s)    Description    (Table 0765)
  1830.  0    DEBUG=ROMSWAP
  1831.  1    DEBUG=UNSHADOWROM
  1832.  2    DEBUG=COMPROM
  1833.  3    DEBUG=DPMIPHYS
  1834.  4    DEBUG=ALLROM
  1835.  5    DEBUG=VMS
  1836.  6    DEBUG=XMS (generate INT 01 on XMS calls)
  1837.  7    DEBUG=I06
  1838.  8    DEBUG=VCPI
  1839.  9    DEBUG=XDMA
  1840.  10    DEBUG=X09
  1841.  13    DEBUG=I67 (generate INT 01 on every INT 67 call)
  1842.  14    DEBUG=EVM (generate INT 01 on entering V86 mode)
  1843.  15    DEBUG=EMSSAVE or DEBUG=VDS
  1844.  
  1845. Bitfields for 386MAX debugging flags 3:
  1846. Bit(s)    Description    (Table 0766)
  1847.  10    DEBUG=EPM
  1848.  12    DEBUG=ABIOS
  1849.  13    DEBUG=XMSPTED
  1850.  14    DEBUG=TIME
  1851.  15    DEBUG=SCRUB
  1852.  
  1853. Bitfields for 386MAX feature flags 1:
  1854. Bit(s)    Description    (Table 0767)
  1855.  1    Weitek present
  1856.  2    no DPMI services
  1857.  3    NODMA
  1858.  4    TERSE
  1859.  5    NOROM
  1860.  6    NOPARITY
  1861.  8    NOFLEX (IGNOREFLEXFRAME)
  1862.  11    don't create UMBs
  1863.  12    don't backfill below video memory (NOLOW)
  1864.  13    FRAME= specified
  1865.  14    EXT= specified
  1866.  15    NOEMS, allow prior expanded memory manager to provide EMS
  1867.  
  1868. Bitfields for 386MAX feature flags 2:
  1869. Bit(s)    Description    (Table 0768)
  1870.  0    UNSHIFT specified (FORCEA20 disabled)
  1871.  1    NOXRAM
  1872.  2    NOSCSI specified
  1873.  3    SCREEN specified
  1874.  4    enabled EISADMA
  1875.  5    slow DMA
  1876.  6    RESETKEYB specified
  1877.  7    ???
  1878.  9    TOP384
  1879.  10    ???
  1880.  11    NOWARMBOOT
  1881.  12    USE= specified
  1882.  13    ROM= specified
  1883.  
  1884. Bitfields for 386MAX feature flags 3:
  1885. Bit(s)    Description    (Table 0769)
  1886.  0    Windows3 support enabled
  1887.  1    SHADOWROM
  1888.  2    don't compress ROM (NOCOMPROM)
  1889.  3    ??? (related to PRGREG=)
  1890.  4    ??? (related to PRGREG=)
  1891.  5    SHADOWRAM
  1892.  6    DOS4 specified
  1893.  7    NOLOADHIGH
  1894.  8    NOPULSE
  1895.  11    FORCEA20
  1896.  12    DMA buffer enabled
  1897.  13    NOSCRUB
  1898.  15    NOFRAME
  1899.  
  1900. Bitfields for 386MAX machine type:
  1901. Bit(s)    Description    (Table 0770)
  1902.  12    Amstrad
  1903.  13    Epson
  1904.  14    Zenith Data Systems
  1905.  15    "ASEM"
  1906.  16    NEC
  1907.  17    "HPRS" model codes 69h and 6Ah
  1908.  18    Dell
  1909.  19    "CA"
  1910.  20    ITT (Xtra Business Systems/Alcatel)
  1911.  21    Toshiba 5100
  1912.  22    Olivetti
  1913.  23    Quadram Quad386 (BIOS model FEh, submodel A6h)
  1914.  24    Tandy???
  1915.  25    AST 386
  1916.  26    INBOARD, ??? version
  1917.  27    INBOARD, ??? version
  1918.  28    INBOARD, ??? version
  1919.  29    "HPRS"
  1920.  30    Compaq 386
  1921.  31    JET386
  1922.  
  1923. Format of 386MAX control block:
  1924. Offset    Size    Description    (Table 0771)
  1925.  00h    WORD    segment of next block (FFFFh if last)
  1926.  02h    WORD    segment of previous block (FFFFh if first)
  1927.  04h 12 BYTEs    filename
  1928.  10h    WORD    resident size in paragraphs
  1929.  12h    WORD    environment size???
  1930.  14h    WORD    real prsent environment size + 1 (0000h if ENVSAVE used)
  1931.  16h  2 BYTEs    ???
  1932.  18h    DWORD    initial size or SIZE=n in 386LOAD commandline
  1933.  1Ch    DWORD    SIZE=-1 ???
  1934.  20h    DWORD    SIZE= ???
  1935.  24h    BYTE    PRGREG= if specified, else FFh
  1936.  25h    BYTE    ENVREG= if specified, else FFh
  1937.  26h    BYTE    FlexFrame (00h not present, 01h present)
  1938.  27h  3 BYTEs    ???
  1939.  2Ah    BYTE    GROUP= or 00h if not present
  1940.  2Bh    BYTE    ???
  1941.  2Ch    WORD    PSP
  1942.  
  1943. Format of 386MAX high memory info record:
  1944. Offset    Size    Description    (Table 0772)
  1945.  00h    WORD    segment address of memory region
  1946.  02h    WORD    size of memory region in paragraphs
  1947.  04h    BYTE    type or flags???
  1948.         00h if locked out
  1949.         02h if EMS page frame
  1950.         04h if high RAM
  1951.         42h if ROM
  1952.  05h    BYTE    ???
  1953.  
  1954. Format of 386MAX ROM shadowing record:
  1955. Offset    Size    Description    (Table 0773)
  1956.  00h    WORD    logical start segment of ROM??? (may be used by BlueMAX when it
  1957.           squeezes together the ROMs to make room)
  1958.  02h    WORD    physical start segment of ROM
  1959.  04h  2 BYTEs    ???
  1960.  06h    WORD    size of shadowed ROM in paragraphs
  1961.  08h  2 BYTEs    ???
  1962.  0Ah    WORD    flags
  1963.         bit 15: shadowing enabled for this ROM???
  1964.         bit 14: ???
  1965.         bit 13: ???
  1966.         bit 12: ???
  1967.         bit 10: ???
  1968.  
  1969. (Table 0774)
  1970. Values for 386MAX memory type:
  1971.  00h    unused by EMS
  1972.  01h    DOS
  1973.  04h    page frame overlapping ROM???
  1974.  80h    high memory
  1975.  84h    page frame???
  1976.  87h    video ROM???
  1977. Note:    the type may be 00h (unused) if the 16K page is split among different
  1978.       uses (such as ROM and high RAM)
  1979.  
  1980. (Table 0775)
  1981. Call 386MAX API (via OUT DX,AL) with:
  1982.     STACK: WORD value for DX
  1983.     AH = 00h unused
  1984.         Return: AH = 84h (unsupported function)
  1985.     AH = 01h get high memory information
  1986.         ES:DI -> buffer for array of high memory info records
  1987.             (see #0772)
  1988.         Return: CX = number of records placed in buffer
  1989.     AH = 02h get shadowed ROM info
  1990.         ES:DI -> buffer for array of ROM shadowing records (see #0773)
  1991.         Return: CX = number of records placed in buffer
  1992.     AH = 03h get 386MAX state
  1993.         ES:DI -> 90-byte buffer for state (see #0761)
  1994.         Return: AH = 00h (successful)
  1995.             buffer filled
  1996.     AH = 04h get memory types???
  1997.         ES:DI -> buffer for memory type info (array of bytes, one per
  1998.             16K page) (see #0774)
  1999.         Return:    CX = number of bytes placed in buffer
  2000.     AH = 05h get page table entries
  2001.         AL = A20 control (00h enable A20 first, 01h leave unchanged)
  2002.         CX = buffer size in bytes (0000h = enough for all memory from
  2003.             given start to end of memory managed by 386MAX)
  2004.         SI = first K to report (rounded down to 4K page)
  2005.         ES:DI -> buffer for returned page table entries
  2006.         Return: CX = number of bytes returned (four per 4K page)
  2007.             ES:DI buffer filled
  2008.     AH = 06h get memory speed info
  2009.         ES:DI -> buffer for memory speed records (see #0776)
  2010.         Return: AH = 00h (successful)
  2011.             CX = number of bytes placed in buffer
  2012.         Note:    this function can take over a second to execute
  2013.     AH = 07h map/unmap multiple handle pages
  2014.         DX = EMS handle (on stack)
  2015.         STACK: DWORD -> EMS mapping record
  2016.         Return:    AH = status (00h,80h,83h,8Ah,8Bh)
  2017.         Format of EMS mapping record:
  2018.         Offset    Size    Description
  2019.          00h    WORD    function
  2020.                 0000h use physical page numbers
  2021.                 0001h use segment addresses
  2022.          02h    WORD    EMS handle
  2023.          04h    WORD    number of mapping entries following
  2024.          06h 2N WORDs    logical page number and physical page/segment
  2025.                 logical page FFFFh means unmap physical page
  2026.         SeeAlso: INT 67/AH=50h
  2027.     AH = 08h "EMM2_GOREAL" check whether possible to disable 386MAX
  2028.         AL = ??? (00h or nonzero)
  2029.         Return: AH = status (00h OK, A4h not possible at this time)
  2030.         Note:    if AL=00h, this function always returns success
  2031.     AH = 09h toggle Bit Flags 1 flags
  2032.         BX = bitmask of bit flags 1's flags to toggle (see #0762)
  2033.         Return: AH = 00h (successful)
  2034.         Note:    enables A20 first
  2035.     AH = 0Ah toggle Debugging Flags 1 flags
  2036.         BX = bitmask of Debugging Flags 1's bits to toggle (see #0764)
  2037.         Return: AH = 00h (successful)
  2038.         Notes:    enables A20 first
  2039.             does ??? if bit 3 on after specified bits are toggled
  2040.     AH = 0Bh toggle Debugging Flags 2 flags
  2041.         BX = bitmask of Debugging Flags 2's bits to toggle (see #0765)
  2042.         Return: AH = 00h (successful)
  2043.         Note:    enables A20 first
  2044.     AH = 0Ch toggle feature flags 3
  2045.         BX = bitmask of feature flags 3's bits to toggle (see #0769)
  2046.         Return: AH = 00h (successful)
  2047.         Note:    enables A20 first
  2048.     AH = 0Dh specify 386MAX high-memory location
  2049.         BX = segment address of high-memory real-mode portion of 386MAX
  2050.         CX = current segment of real-mode stub???
  2051.         Return: AH = status (00h successful)
  2052.             ???
  2053.     AH = 0Eh CRT controller register virtualization
  2054.         AL = subfunction
  2055.             00h allow access to CRTC I/O ports 03B4h/03B5h, 03D4h/03D5h
  2056.             01h trap accesses to CRTC I/O ports
  2057.     AH = 0Fh reboot system
  2058.         Return: never
  2059.     AH = 10h unused
  2060.         Return: AH = 84h (unsupported function)
  2061.     AH = 11h get high memory information
  2062.         ES:DI -> 96-byte buffer for high memory info
  2063.         Return: AH = 00h (successful)
  2064.             ES:DI buffer filled
  2065.         Notes:    each byte in buffer contains bit flags for a 4K page in
  2066.               the A000h-FFFFh region
  2067.                 bit 0: page is writeable
  2068.                 bit 1: physical address same as linear address
  2069.                 bit 2: EMS page frame
  2070.                 bit 6: page is part of the QPMS window
  2071.             this function can take over a second to execute,
  2072.               because it does a 128K read for each page in an
  2073.               attempt to flush any RAM cache the system may have
  2074.     AH = 12h shadow RAM mapping
  2075.         AL = subfunction
  2076.             00h unshadow ROMs (except page FFh if NOWARMBOOT set)
  2077.             01h map shadow RAM into ROM regions???
  2078.         Return: AH = 00h (successful) if AL=00h or 01h
  2079.             AH = 8Fh otherwise
  2080.     AH = 13h shadow RAM page protection
  2081.         AL = subfunction
  2082.             00h set all shadowed ROM 4K pages to read-only
  2083.             01h set all shadowed ROM 4K pages to read-write
  2084.         Return: AH = 00h (successful) if AL=00h or 01h
  2085.             AH = 8Fh otherwise
  2086.     AH = 14h get Programmable Option Select info???
  2087.         ES:DI -> 54-byte buffer for POS data???
  2088.         Return: AH = 00h if successful
  2089.             AH = A4h on error
  2090.         Note:    the buffer consists of nine 6-byte fields; the first
  2091.               eight for slots 1-8, the last for the system board
  2092.     AH = 15h ???
  2093.         ???
  2094.         Return: ???
  2095.     AH = 16h get 386MAX memory usage screen
  2096.         ES:DI -> buffer for memory info display
  2097.         CX = size of buffer in bytes
  2098.         Return:    ES:DI buffer filled with '$'-terminated string (if
  2099.                 large enough to hold entire usage screen)
  2100.         Note:    the screen is 0303h bytes in v7.00
  2101.     AH = 17h Windows 3 startup/termination
  2102.         AL = subfunction
  2103.             00h Windows3 initializing
  2104.             DX (on stack) = Windows startup flags
  2105.             DI = Windows version number (major in upper byte)
  2106.             ES:BX = 0000h:0000h
  2107.             DS:SI = 0000h:0000h
  2108.             Return: CX = 0000h if OK for Windows to load
  2109.                    <> 0 if Windows should not load
  2110.                 ES:BX -> startup info structure
  2111.                 DS:SI -> Virtual86 mode enable/disable callback
  2112.             01h Windows3 terminating
  2113.             ES:BX -> ???
  2114.             DX (on stack) = Windows exit flags
  2115.             Return: ???
  2116.     AH = 18h QPMS (Qualitas Protected Memory Services)
  2117.         AL = subfunction
  2118.             00h get QPMS configuration
  2119.             Return: BX = starting segment of QPMS memory window
  2120.                 CX = number of 4K pages reserved for QPMS???
  2121.                 DX = number of 4K pages in QPMS window???
  2122.             01h map QPMS memory page???
  2123.             BX = 4K page number within memory reserved for QPMS???
  2124.             CL = 4K page number within QPMS memory window???
  2125.             02h mark all QPMS memory read-only
  2126.             03h mark all QPMS memory read-write
  2127.         Return: AH = status (00h,8Ah,8Bh,8Fh)
  2128.     AH = 19h get linear address for physical address
  2129.         EDX = physical address (low word on stack)
  2130.         Return: AH = status
  2131.                 00h successful
  2132.                 EDX = linear address at which physical address
  2133.                     may be accessed
  2134.                 8Bh physical address currently not addressable
  2135.         Note:    enables A20 first
  2136.     AH = 1Ah set page table entry
  2137.         EDX = new page table entry (low word on stack)
  2138.         ESI = linear address of page to map (bits 0-11 clear)
  2139.         Return: AH = status (00h,8Bh)
  2140.         Note:    enables A20 first
  2141.     AH = 1Bh get ???
  2142.         Return: AH = status
  2143.             BX = ???
  2144.             CX = number of ???
  2145.             EDX = physical address of ???
  2146.     AH = 1Ch get original interrupt vector
  2147.         AL = interrupt vector (00h-7Fh)
  2148.         Return: AH = 00h (successful)
  2149.             EDX = original vector before 386MAX loaded (segment in
  2150.                 high word, offset in low word)
  2151.         Note:    no range checking is performed; requests for INTs 80h-
  2152.               FFh will return random values
  2153.     AH = 1Dh display string???
  2154.         SI = ???
  2155.         Return: AH = 00h (successful)
  2156.             ???
  2157.         Note:    this function appears to be broken in v7.00
  2158.     AH = 1Eh get memory info
  2159.         ES:DI -> memory info (see #0777)
  2160.         Return: ???
  2161.     AH = 1Fh get DPMI host information
  2162.         Return: AX = 0000h if successful
  2163.             BX = DPMI flags (see #2302 at INT 31/AX=0400h)
  2164.             CL = CPU type (02h = 80286, 03h = 80386, etc.)
  2165.             DX = DPMI ver supported (DH=major, DL=2-digit minor)
  2166.             SI = ???
  2167.             ES???:DI -> ???
  2168.         Note:    NOP if NODPMI switch specified
  2169.     AH = 20h (v7.00) get ???
  2170.         AL = index of ???
  2171.         Return: EDX = ??? for specified ???
  2172.     AH = 21h (v7.00) STACKS support
  2173.         AL = 00h get STACKS parameters
  2174.         Return: BX = ??? (0060h for v7.00)
  2175.             CX = number of stacks for hardware interrupts
  2176.             DX = size of each stack in bytes
  2177.             SI = ??? (low and high bytes are separate values)
  2178.             DI = ??? (low and high bytes are separate values)
  2179.                 low byte = logical page number set by subfn 02h
  2180.             ES = ???
  2181.         AL = 01h set ??? "EMM2_DSTKS"
  2182.         EBX = ???
  2183.         ECX = ???
  2184.         AL = 02h set ???
  2185.         BL = logical page number for ??? (00h-03h)
  2186.         Return: AH = status (00h,8Ah)
  2187.     AH = 22h (v7.00) call ??? for every load module
  2188.         AL = which function to call
  2189.         00h call ???
  2190.         else call ????
  2191.         Return: AH = 00h
  2192.         Note: if AL=00h, calls the protected-mode function pointed at by
  2193.         the DWORD at offset 22h from the start of each module installed
  2194.         by a LOAD= directive; if AL<>00h, it calls the function
  2195.         pointed at by the DWORD at offset 28h of the load module
  2196.     AH = 23h (v7.00) ???
  2197.         AL = 00h set ???
  2198.         BL = ???
  2199.         Return:    AH = 00h or unchanged (depending on ???)
  2200.         AL = 01h set ???
  2201.         BL = ???
  2202.         BH = ???
  2203.         CX = ???
  2204.         DX = ??? (on top of stack)
  2205.         Return: AH = status (00h if successful, 8Fh once table full)
  2206.         Note:    this call adds one entry to an internal table on each
  2207.               call, until the table is full
  2208.         AL = 02h get ???
  2209.         CX = size of buffer
  2210.         ES:DI -> buffer for ??? (60 bytes total data)
  2211.         Return: CX = number of bytes actually returned
  2212.         Note:    returns the array storing the values set with AX=2301h
  2213.         Format of one entry in array:
  2214.         Offset    Size    Description
  2215.          00h    BYTE    ??? (BL from subfn 01h)
  2216.          01h    WORD    ??? (CX from subfn 01h)
  2217.          03h    BYTE    ??? (BH from subfn 01h)
  2218.          04h    WORD    ??? (DX from subfn 01h)
  2219.         AL = 03h set ??? name/path
  2220.         ES:DI -> buffer containing ASCIZ ???
  2221.         AL = 04h get ???
  2222.         ES:DI -> buffer for ASCIZ ???
  2223.         Note: the ASCIZ string for subfunctions 03h and 04h does not appear
  2224.         to be used by 386MAX, and may serve merely for communication
  2225.         between two other Qualitas programs
  2226.     AH = 24h (v7.00) high memory control
  2227.         AL = 00h get high memory state
  2228.         Return: BX = current state
  2229.                 00h high memory removed from DOS memory chain
  2230.                 01h high memory included in DOS memory chain
  2231.         AL = 01h set high memory state
  2232.         BX = new state
  2233.             00h high memory removed from DOS memory chain
  2234.             01h high memory included in DOS memory chain
  2235.             else
  2236.             Return: ??? (error, but return varies according to ???)
  2237.     AH = 25h (v7.00) remove high RAM from DOS memory chain
  2238.     AH = 26h (v7.00) ???
  2239.         BX = ???
  2240.         CX = ???
  2241.         SI = ???
  2242.         DI = ???
  2243.         Return: AH = status
  2244.             BX = ???
  2245.             CX = ???
  2246.     AH = 27h (v7.00) ???
  2247.         AL = 00h get ???
  2248.         Return: BX = number of paragraphs for ???
  2249.         AL = 01h ???
  2250.         BX = ???
  2251.         ES??? = ???
  2252.         AL = 02h ???
  2253.         ???
  2254.         AL = 03h ???
  2255.         CX = ???
  2256.         DX = ???
  2257.         ES??? = ???
  2258.         Return: ???
  2259.     AH = 28h (v7.00) get ???
  2260.         Return: AH = status (00h,8Fh) (see #2778 at INT 67/AH=40h)
  2261.             if AH=00h,
  2262.                 CX = ???
  2263.                 DX = ???
  2264.     AH = 29h (v7.00) get ???
  2265.         Return: AX = ???
  2266.     AH = 40h-5Dh EMS services (see INT 67/AH=40h etc)
  2267.     AH = DEh VCPI services (see INT 67/AX=DE00h etc)
  2268. Return: AH = status (as for EMS INT 67 calls)
  2269.         00h successful
  2270.         80h internal error
  2271.         81h hardware malfunction
  2272.         83h invalid handle
  2273.         84h    undefined function
  2274.         8Ah invalid logical page nuber
  2275.         8Bh illegal physical page number
  2276.         8Fh undefined subfunction
  2277.         A4h access denied
  2278.         etc.
  2279.     STACK popped (value placed in DX if no specific return value for DX)
  2280.  
  2281. Format of 386MAX memory speed record:
  2282. Offset    Size    Description    (Table 0776)
  2283.  00h    DWORD    page table entry for 4K page
  2284.  04h    WORD    number of microticks (840ns units) required for REP LODSD of
  2285.           entire 4K page
  2286.  
  2287. Format of 386MAX memory info [array]:
  2288. Offset    Size    Description    (Table 0777)
  2289.  00h    DWORD    linear start address
  2290.  04h    DWORD    size in bytes
  2291.  08h    WORD    XMS handle (if next byte = 04h)
  2292.         ??? (if next byte = 05h)
  2293.         ??? (if next byte = 06h)
  2294.         ??? (if next byte = 13h)
  2295.         ??? (if next byte = 14h)
  2296.         ??? (if next byte = 15h)
  2297.         ??? (if next byte = 23h)
  2298.         ??? (if next byte = 24h)
  2299.         ??? (if next byte = 26h)
  2300.         else unused
  2301.  0Ah    BYTE    type
  2302.         00h = ???, 01h = VDISK,
  2303.         02h = INT 15h extended memory, 03h = ??? extended,
  2304.         04h = XMS handle's memory, 05h = ???, 06h = ???, 07h = ???,
  2305.         08h = ???, 09h = ???, 0Ah = ???, 0Bh = ???,
  2306.         11h = ???, 12h = ???, 14h = ???, 15h = ???,
  2307.         19h = ???, 1Ah = ???, 1Bh = ???,
  2308.         1Ch = ???, 1Dh = ???, 1Eh = ???, 1Fh = ???,
  2309.         20h = ???, 21h = ???, 23h = ???, 24h = ???,
  2310.         26h = ???
  2311.  0Bh    BYTE    ??? (00h for types 00h-03h, 07h-0Bh, 19h-21h;
  2312.              80h for types 04h/13h-15h/23h-26h;
  2313.             ??? for type 05h)
  2314. --------V-214402-----------------------------
  2315. INT 21 - PGS1600.DEV - IOCTL - GET CONFIGURATION INFO
  2316.     AX = 4402h
  2317.     BX = file handle for device "PGS1600$"
  2318.     CX = 0018h (size of buffer)
  2319.     DS:DX -> configuration buffer (see #0778)
  2320. Return: CF clear if successful
  2321.         buffer filled
  2322.         AX = number of bytes actually copied
  2323.     CF set on error
  2324.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2325. Program: PGS1600.DEV is a device driver for the Cornerstone Technology PG1600
  2326.       display adapter, which provides a 1600x1200 monochrome display as
  2327.       well as one of two emulations, MDA or CGA.
  2328. SeeAlso: AX=4403h"PGS1600"
  2329.  
  2330. Format of PGS1600.DEV configuration information:
  2331. Offset    Size    Description    (Table 0778)
  2332.  00h    WORD    version (high byte = major, low byte = minor)
  2333.  02h    WORD    board initialisation mode
  2334.  04h    WORD    board I/O address
  2335.         03D0h CGA emulation
  2336.         03B0h MDA emulation
  2337.         0390h no emulation
  2338.         0350h no emulation, alternate
  2339.  06h    WORD    emulation buffer segment
  2340.         B800h    CGA emulation
  2341.         B000h    MDA emulation
  2342.         0000h    no emulation
  2343.  08h    WORD    PG1600 graphics buffer segment
  2344.  0Ah    WORD    number of bytes between consecutive graphic rows
  2345.  0Ch    WORD    horizontal pixel size
  2346.  0Eh    WORD    vertical pixel size
  2347.  10h    WORD    horizontal dots per inch
  2348.  12h    WORD    vertical dots per inch
  2349.  14h    WORD    graphics buffer bits per pixel
  2350.  16h    WORD    monitor bits per pixel
  2351. --------N-214402-----------------------------
  2352. INT 21 - PC/TCP IPCUST.SYS - RESET CONFIGURATION DATA READ POINTER
  2353.     AX = 4402h
  2354.     BX = file handle referencing device "$IPCUST"
  2355.     CX, DS:DX ignored
  2356. Return: CF clear if successful
  2357.         AX destroyed
  2358.     CF set on error
  2359.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2360. Notes:    there are a total of 378h bytes of configuration data for IPCUST.SYS
  2361.       version 2.05.     If less than the entire data is read or written,
  2362.       the next read/write continues where the previous one ended; this
  2363.       call and AX=4403h both reset the location at which the next
  2364.       operation starts to zero
  2365.     v2.1+ uses a new configuration method, but allows the installation
  2366.       of IPCUST.SYS for backward compatibility with other software which
  2367.       must read the PC/TCP configuration
  2368. SeeAlso: AH=3Fh"IPCUST",AH=40h"IPCUST",AX=4403h"IPCUST"
  2369. --------N-214402-----------------------------
  2370. INT 21 - WORKGRP.SYS - GET API ENTRY POINT
  2371.     AX = 4402h
  2372.     BX = file handle for device "NET$HLP$"
  2373.     CX = 0008h
  2374.     DS:DX -> buffer for entry point record (see #0779)
  2375. Return: CF clear if successful
  2376.         AX = number of bytes actually read
  2377.     CF set on error
  2378.         AX = error code
  2379. Program: WORKGRP.SYS is the portion of Microsoft's Workgroup Connection which
  2380.       permits communication with PCs running Windows for Workgroups or
  2381.       LAN Manager
  2382. SeeAlso: AH=3Fh"WORKGRP.SYS"
  2383.  
  2384. Format of WORKGRP.SYS entry point record:
  2385. Offset    Size    Description    (Table 0779)
  2386.  00h    WORD    3633h  \ signature???
  2387.  02h    WORD    EF6Fh  /
  2388.  04h    DWORD    address of entry point (see #0780)
  2389. Note:    first four bytes of buffer must be 6Fh E9h 33h 36h on entry when using
  2390.       IOCTL rather than READ to get the entry point record
  2391.  
  2392. (Table 0780)
  2393. Call WORKGRP entry point with:
  2394.     STACK:    WORD    function number (0000h-0009h)
  2395. Return: STACK unchanged
  2396. SeeAlso: #0781,#0782,#0783,#0784,#0785,#0786,#0787,#0788
  2397.  
  2398. (Table 0781)
  2399. Call WORKGRP function 00h with:
  2400.     STACK:    WORD    0000h (function "get ???")
  2401. Return: DX:AX -> data table
  2402.  
  2403. (Table 0782)
  2404. Call WORKGRP function 01h with:
  2405.     STACK:    WORD    0001h (function "hook ???")
  2406. Return: STACK:    DWORD    pointer to ???
  2407.         WORD    0001h (function number)
  2408.  
  2409. (Table 0783)
  2410. Call WORKGRP function 02h with:
  2411.     STACK:    WORD    0002h (function "unhook ???")
  2412.     ???
  2413. Return: ???
  2414.  
  2415. (Table 0784)
  2416. Call WORKGRP function 03h with:
  2417.     STACK:    WORD    0003h (function "reenable printer port")
  2418.         WORD    LPT port number
  2419. Return: ???
  2420.  
  2421. (Table 0785)
  2422. Call WORKGRP function 04h with:
  2423.     STACK:    WORD    0004h (function "disable printer port")
  2424.         WORD    LPT port number
  2425. Return: ???
  2426.  
  2427. (Table 0786)
  2428. Call WORKGRP function 05h with:
  2429.     STACK:    WORD    0005h (function "???")
  2430.         ???
  2431. Return: ???
  2432.  
  2433. (Table 0787)
  2434. Call WORKGRP function 06h with:
  2435.     STACK:    WORD    0006h (function "???")
  2436. Return: STACK unchanged
  2437.     AX = 0000h
  2438.     DX = 0000h
  2439.  
  2440. (Table 0788)
  2441. Call WORKGRP functions 07h-09h with:
  2442.     STACK:    WORD    0007h-0009h (NOP functions)
  2443. Return: STACK unchanged
  2444.     AX = 0001h
  2445.     DX = 0000h
  2446. --------N-214402-----------------------------
  2447. INT 21 - 10NET v5.0 - 10BEUI.DOS - API
  2448.     AX = 4402h
  2449.     BX = file handle referencing device "10BEUI$"
  2450.     DS:DX -> parameter record (see #0789)
  2451.     CX ignored
  2452. Return: CF clear if successful
  2453.         AX destroyed
  2454.     CF set on error
  2455.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2456. SeeAlso: AX=4402h"10MEMMGR",INT 6F/AH=00h"10NET"
  2457.  
  2458. Format of 10NET 10BEUI.DOS parameter record:
  2459. Offset    Size    Description    (Table 0789)
  2460.  00h    WORD    000Ah (function number???)
  2461.  02h    WORD    ???
  2462.  04h    DWORD    pointer to buffer for ???
  2463.  08h  4 BYTEs    ???
  2464.  0Ch    WORD    transfer size
  2465. --------N-214402-----------------------------
  2466. INT 21 - 10NET v5.0 - 10MEMMGR.SYS - API
  2467.     AX = 4402h
  2468.     BX = file handle referencing device "MEMMGR0$"
  2469.     DS:DX -> 6-byte buffer for interface info (see #0790)
  2470.     CX ignored
  2471. Return: CF clear if successful
  2472.         AX destroyed
  2473.     CF set on error
  2474.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2475. SeeAlso: AX=4402h"10BEUI",INT 6F/AH=00h"10NET"
  2476.  
  2477. Format of 10NET 10MEMMGR.SYS interface info:
  2478. Offset    Size    Description    (Table 0790)
  2479.  00h    DWORD    address of entry point (see #0791)
  2480.  04h    WORD    version (0500h for v5.00)
  2481.  
  2482. (Table 0791)
  2483. Call 10NET 10MEMMGR.SYS entry point with:
  2484.     AL = 01h ???
  2485.         BX = ???
  2486.         Return: CF clear if successful
  2487.             CF set on error
  2488.             AX = error code
  2489.     AL = 02h ???
  2490.         ???
  2491.     AL = 03h ???
  2492.         ???
  2493.     AL = 04h set/restore memory allocation strategy
  2494.         BX = subfunction
  2495.         0000h set strategy
  2496.         0001h restore strategy
  2497.         Return: CF clear if successful
  2498.             CF set on error (if function disabled)
  2499.             various registers destroyed
  2500.     AL = other
  2501.         Return: CF set
  2502.             AX = 0000h
  2503.             BL = 01h
  2504. --------V-214402-----------------------------
  2505. INT 21 - Compaq AG1024.SYS - RGDI - GET DRIVER LOCATION
  2506.     AX = 4402h
  2507.     BX = file handle for device "$$$$RGDI"
  2508.     CX = 0006h (size of returned data)
  2509.     DS:DX -> location record (see #0792)
  2510. Return: CF clear if successful
  2511.         buffer filled
  2512.     CF set on error
  2513.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2514. Program: AG1024.SYS is a device driver for the Advanced Graphics 1024 adapter
  2515. SeeAlso: AX=4403h"RGDI"
  2516.  
  2517. Format of Compaq AG1024.SYS location record:
  2518. Offset    Size    Description    (Table 0792)
  2519.  00h    WORD    signature 55AAh
  2520.  02h    WORD    segment of ???
  2521.  04h    WORD    segment of device driver's code
  2522. --------N-214402-----------------------------
  2523. INT 21 - FTPSOFT.DOS v3.1 - GET ???
  2524.     AX = 4402h
  2525.     BX = file handle for device "FTPSOFT$"
  2526.     CX = size of buffer
  2527.     DS:DX -> buffer for data (see #0793)
  2528. Return: CF clear if successful
  2529.         buffer filled
  2530.     CF set on error
  2531.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2532. Program: FTPSOFT.DOS is a device driver for Protocol Manager support from
  2533.        FTP Software, Inc.
  2534. SeeAlso: AH=3Fh"PC/TCP",AX=4402h"NDIS"
  2535.  
  2536. Format of FTPSOFT.DOS data:
  2537. Offset    Size    Description    (Table 0793)
  2538.  00h    WORD    (call) BA98h (if different, no data returned)
  2539.  02h    DWORD    -> NDIS common characteristics table
  2540.           (see #0732 at AX=4402h"NDIS")
  2541.  06h    DWORD    (call) -> new dispatch table (see #0734 at AX=4402h"NDIS")
  2542.  0Ah    DWORD    -> 28-byte buffer for ??? data
  2543.  0Eh    DWORD    ???
  2544.  12h    DWORD    -> FAR function to reset dispatch jump table to defaults
  2545.  16h    BYTE    ???
  2546. Note:    the addresses in the new dispatch table are copied into an internal
  2547.       jump table which may be reset by calling the function pointed at by
  2548.       offset 12h
  2549. --------n-214402-----------------------------
  2550. INT 21 U - PenDOS PENDEV.SYS - GET ENTRY POINTS
  2551.     AX = 4402h
  2552.     BX = file handle for device "$$PENDOS" or "$$PD_REG"
  2553.     CX = size of buffer (4 for $$PENDOS and a 4,8,12, or 16 for $$PD_REG)
  2554.     DS:DX -> buffer for entry point record (see #0794)
  2555. Return: CF clear if successful
  2556.         buffer filled
  2557.     CF set on error
  2558.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2559. Program: A limited version of PenDOS by Communication Intelligence Corporation,
  2560.       which provides pen capability to keyboard-based programs, is bundled
  2561.       with IBM DOS 6.1
  2562. SeeAlso: AX=4403h"PENDEV.SYS"
  2563.  
  2564. Format of PENDEV.SYS entry point record:
  2565. Offset    Size    Description    (Table 0794)
  2566.  00h    DWORD    -> array of jumps
  2567.  04h    WORD    offset of function to retrieve entry point (see #0795)
  2568.  06h  2 BYTEs    signature "Pe"
  2569.  08h    WORD    offset of function to set entry point (see #0796)
  2570.  0Ah  2 BYTEs    signature "nD"
  2571.  0Ch    WORD    offset of function to clear entry point (see #0797)
  2572.  0Eh    WORD    signature "OS"
  2573.  
  2574. (Table 0795)
  2575. Call PENDEV.SYS function to retrieve entry point with:
  2576.     AX = index of entry point (0-9)
  2577. Return: CF clear if successful
  2578.         DX:AX -> desired entry point
  2579.     CF set on error (AX out of range)
  2580.  
  2581. (Table 0796)
  2582. Call PENDEV.SYS function to set entry point with:
  2583.     AX = index of entry point (0-9)
  2584.     DX:SI -> new handler
  2585. Return: CF clear if successful
  2586.     CF set on error (AX out of range)
  2587.  
  2588. (Table 0797)
  2589. Call PENDEV.SYS function to clear entry point with:
  2590.     AX = index of entry point (0-9)
  2591. Return: CF clear if successful
  2592.     CF set on error (AX out of range)
  2593. Note:    resets the jump at the specified entry point to its default target,
  2594.       which simply returns
  2595. --------N-214402-----------------------------
  2596. INT 21 U - LAN Manager - TCPDRV.DOS - API
  2597.     AX = 4402h
  2598.     BX = file handle referencing device "TCPDRV$"
  2599.     CX = 0019h
  2600.     DS:DX -> buffer containing request block (see #0798)
  2601. Return: CF clear if successful
  2602.         buffer filled
  2603.     CF set on error
  2604.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2605. Program: TCPDRV.DOS is the low-level device driver supporting LAN Manager's
  2606.       TCP/IP protocol stack
  2607.  
  2608. Format of TCPDRV.DOS request block:
  2609. Offset    Size    Description    (Table 0798)
  2610.  00h    BYTE    (call) function number
  2611.         00h initialize ???
  2612.         06h get ???
  2613.         07h get ???
  2614.  01h    BYTE    (call) 00h
  2615.         (ret) error code if error, unchanged if successful
  2616.  02h    WORD    signature 4354h ('CT')
  2617. ---function 00h---
  2618.  04h    DWORD    (call) pointer to ??? FAR function
  2619.         function is called with ES:BX -> device driver request used to
  2620.           invoke this function
  2621.  08h  4 BYTEs    ???
  2622.  0Ch    DWORD    (call) pointer to ??? record, WORD at offset 22h is read
  2623.  10h    DWORD    (ret) -> ??? buffer if 0000h:0000h on call
  2624. ---function 06h---
  2625.  04h  4 BYTEs    ???
  2626.  08h    DWORD    (ret) pointer to ???
  2627. ---function 07h---
  2628.  04h    DWORD    (ret) pointer to ??? record
  2629. --------y-214402-----------------------------
  2630. INT 21 U - PC Tools 9 CPRLOW.EXE - GET CODE AND DATA ADDRESSES
  2631.     AX = 4402h
  2632.     BX = file handle referencing device "RECLOWLD"
  2633.     DS:DX -> buffer for address list (see #0799)
  2634.     CX ignored
  2635. Return: CF clear if successful
  2636.         buffer filled
  2637.     CF set on error
  2638.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2639.  
  2640. Format of CPRLOW address list:
  2641. Offset    Size    Description    (Table 0799)
  2642.  00h    WORD    segment of CPRLOW code
  2643.  02h    WORD    offset in code segment of ??? entry point
  2644.         (switches into protected mode)
  2645.  04h    WORD    offset in code segment of jump array (see #0800)
  2646.  06h    WORD    segment of copy of interrupt vector table at CPRLOW load time
  2647. Note:    neither the entry point nor the jump array is valid until after a
  2648.       CPR /LOAD, because CPR.EXE installs the code into CPRLOW at runtime.
  2649.  
  2650. Format of CPRLOW jump array:
  2651. Offset    Size    Description    (Table 0800)
  2652.  00h  3 BYTEs    initialize CPRLOW interrupt hooks
  2653.  03h  3 BYTEs    reset timers and enable CPR (hotkey enable)
  2654.  06h  3 BYTEs    disable CPR (hotkey disable)
  2655.  09h  3 BYTEs    clear ??? flag, hotkey disable, and ???
  2656.  0Ch  3 BYTEs    initialize delay loop counter (destroys AX,BX,CX,DX)
  2657.  0Fh  3 BYTEs    disable CPR completely (commandline /DISABLE)
  2658.  12h  3 BYTEs    enable ??? if CPR enabled by both cmdline and hotkey
  2659.  15h  3 BYTEs    enable CPR (commandline /ENABLE)
  2660. --------s-214402-----------------------------
  2661. INT 21 U - Creative Technology CTMMSYS.SYS v1.00.01 - API
  2662.     AX = 4402h
  2663.     BX = file handle for device "CTMMSYS$"
  2664.     CX = 0004h (size of data)
  2665.     DS:DX -> buffer for entry point (see #0801)
  2666. Return: CF clear if successful
  2667.         buffer updated
  2668.     CF set on error
  2669.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2670. Program: CTMMSYS.SYS is the Creative DOS Multimedia Architecture Integration
  2671.       driver
  2672. SeeAlso: AX=4402h"CTSB2",INT 80/BX=0000h"SBFM"
  2673.  
  2674. Format of CTMMSYS.SYS entry point record:
  2675. Offset    Size    Description    (Table 0801)
  2676.  00h    DWORD    (call) signature 4D6D7443h (ASCII "CtmM")
  2677.         (ret) pointer to CTMMSYS entry point (see #0802)
  2678. SeeAlso: #0803
  2679.  
  2680. (Table 0802)
  2681. Call CTMMSYS.SYS entry point with:
  2682.     AX = ???
  2683.     STACK:    WORD    ???
  2684.         WORD    ???
  2685.         WORD    ??? (0001h,0002h,0005h,0006h)
  2686.         WORD    ???
  2687.         DWORD    -> ???
  2688.         WORD    ???
  2689.         WORD    ???
  2690. Return: DX:AX = ??? or error code
  2691.         0000h:000Bh invalid value for ???
  2692.         0000h:000Fh API call already in progress
  2693. SeeAlso: #0801
  2694. --------s-214402-----------------------------
  2695. INT 21 U - Creative Technology CTSB2.SYS v1.01.01 - API
  2696.     AX = 4402h
  2697.     BX = file handle for device "CTSOUND0"
  2698.     CX = 0004h (size of data)
  2699.     DS:DX -> buffer for entry point (see #0803)
  2700. Return: CF clear if successful
  2701.         buffer updated
  2702.     CF set on error
  2703.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2704. Program: CTMMSYS.SYS is the Creative DOS Multimedia Architecture Integration
  2705.       driver
  2706. SeeAlso: AX=4402h"CTMMSYS",INT 80/BX=0000h"SBFM"
  2707.  
  2708. Format of CTSB2.SYS entry point record:
  2709. Offset    Size    Description    (Table 0803)
  2710.  00h    DWORD    (call) signature 4D6D7443h (ASCII "CtmM")
  2711.         (ret) pointer to CTSB2 entry point (see #0804)
  2712. SeeAlso: #0801
  2713.  
  2714. (Table 0804)
  2715. Call CTSB2.SYS entry point with:
  2716.     AX = ???
  2717.     STACK:    DWORD    -> ???
  2718.         WORD    function number
  2719.             (0100h,0200h,0300h,0400h,0500h,0600h,0701h)
  2720.         DWORD    -> ???
  2721.         WORD    ???
  2722.         WORD    ???
  2723. Return: DX:AX = ??? or error code
  2724.         0000h:0004h invalid subfunction???
  2725.         0000h:000Bh invalid value for ???
  2726.         0000h:000Fh API call already in progress
  2727. SeeAlso: #0803
  2728. --------m-214402-----------------------------
  2729. INT 21 U - Novell DOS 7 EMM386.EXE - GET STATE RECORD???
  2730.     AX = 4402h
  2731.     BX = file handle for device "EMMXXXX0"
  2732.     CX = 003Eh (size of state record)
  2733.     DS:DX -> buffer for state record (see #0805)
  2734. Return: CF clear if successful
  2735.         buffer filled (see #2733 at INT 67/AH=3Fh)
  2736.     CF set on error
  2737.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2738.  
  2739. Format of Novell DOS 7 EMM386.EXE state record:
  2740. Offset    Size    Description    (Table 0805)
  2741.  00h    WORD    signature EDC0h
  2742.  02h 60 BYTEs    ???
  2743. --------m-214402SF00-------------------------
  2744. INT 21 U - Memory Managers - GET API ENTRY POINT
  2745.     AX = 4402h subfn 00h
  2746.     BX = file handle for device "EMMXXXX0"
  2747.     CX = 0006h (size of buffer in bytes)
  2748.     DS:DX -> buffer for API entry point record (see #0806)
  2749.         first byte must be 00h on entry
  2750. Return: CF clear if successful
  2751.         buffer filled (see #2733 at INT 67/AH=3Fh)
  2752.     CF set on error
  2753.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2754. Notes:    this function is supported by Microsoft EMM386.EXE v4.45+ and
  2755.       CEMM v5.10+, and is intended for use by MS Windows as it starts up
  2756.     if no other program has hooked INT 67, an alternate installation
  2757.       check for CEMM is testing for the string
  2758.       "COMPAQ EXPANDED MEMORY MANAGER 386" at offset 14h in the INT 67
  2759.       handler's segment; if present, the word at offset 12h contains the
  2760.       offset of the API entry point
  2761. SeeAlso: AX=4402h/SF=01h,AX=4402h/SF=02h,AX=4402h"EMM386",INT 67/AH=3Fh
  2762.  
  2763. Format of memory manager API entry point record:
  2764. Offset    Size    Description    (Table 0806)
  2765.  00h    WORD    ??? (0022h for CEMM 5.11, 0025h for MS EMM386 v4.45)
  2766.  02h    DWORD    manager's private API entry point
  2767.         (see #0807,#2796 at INT 67/AX=FFA5h)
  2768.  
  2769. (Table 0807)
  2770. Call CEMM v5.10+ entry point with:
  2771.     AH = 00h get memory manager's state
  2772.         Return: AH = state
  2773.             bit 0: turned OFF
  2774.             bit 1: AUTO mode enabled
  2775.     AH = 01h set memory manager's state
  2776.         AL = new state (00h ON, 01h OFF, 02h AUTO)
  2777.         Return: CF clear if successful
  2778.             CF set on error
  2779.     AH = 02h Weitek coprocessor support
  2780.         AL = subfunction
  2781.         00h get Weitek support state
  2782.             Return: AL = status
  2783.                 bit 0: Weitek coprocessor is present
  2784.                 bit 1: Weitek support is enabled
  2785.         01h turn on Weitek support
  2786.         02h turn off Weitek support
  2787.         Return: CF clear if successful
  2788.             CF set on error
  2789.             AH = error code (01h invalid subfunc, 02h no Weitek)
  2790.     AH = 05h get statistics
  2791.         ???
  2792.     AH > 06h
  2793.         Return: CF set
  2794.             AH = 01h (invalid function)
  2795. Notes:    AH=03h,04h,06h are NOPs which return CF clear, presumably for backwards
  2796.       compatibility with earlier versions of CEMM
  2797.     in v5.11, AH=05h merely prints an error message (using INT 21/AH=09h)
  2798.       stating that a different version of CEMM is installed and it is
  2799.       therefore not possible to display the statistics
  2800. --------m-214402SF01-------------------------
  2801. INT 21 U - Memory Managers - GET EMM IMPORT STRUCTURE ADDRESS
  2802.     AX = 4402h subfn 01h
  2803.     BX = file handle for device "EMMXXXX0"
  2804.     CX = 0006h (size of buffer in bytes)
  2805.     DS:DX -> buffer for EMM import structure record (see #0808)
  2806.         first byte must be 01h on entry
  2807. Return: CF clear if successful
  2808.         buffer filled (see also #2733 at INT 67/AH=3Fh)
  2809.     CF set on error
  2810.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2811. Notes:    this function is supported by Microsoft EMM386.EXE v4.45+,
  2812.       QEMM-386 v6+, and CEMM v5.10+, and is intended for use by MS Windows
  2813.       as it starts up
  2814.     for QEMM-386, this call always returns an error if Windows3 support
  2815.       has been disabled with the NW3 switch
  2816. SeeAlso: AX=4402h/SF=00h,AX=4402h"EMM386",INT 2F/AX=D201h/BX=5145h
  2817. SeeAlso: INT 67/AH=3Fh
  2818.  
  2819. Format of EMM import structure record:
  2820. Offset    Size    Description    (Table 0808)
  2821.  00h    DWORD    physical address of EMM import structure (see #0809)
  2822.  04h    BYTE    EMM import structure major version
  2823.  05h    BYTE    EMM import structure minor version
  2824. Note:    version 1.00 contains only EMS information (Windows 3.0+)
  2825.     version 1.10 contains UMB/XMS/HMA/EMS information (Windows 3.1)
  2826.     version 1.11 is version 1.10 plus memory manager maker/product name
  2827. SeeAlso: #2773
  2828.  
  2829. Format of Global EMM Import record:
  2830. Offset    Size    Description    (Table 0809)
  2831.  00h    BYTE    bit flags
  2832.         bit 2: ???
  2833.         bit 3: free EMM386 virtual HMA only if hma_page_table_paddr!=0
  2834.         bit 4: no UMB???
  2835.  01h    BYTE    reserved (0)
  2836.  02h    WORD    size of structure in bytes
  2837.  04h    WORD    structure version
  2838.  06h    DWORD    reserved
  2839.  0Ah 384 BYTEs    64 EMS frame status records (see #0810), one per 16K of
  2840.           real-mode 1M address space
  2841. 18Ah    BYTE    ??? (must be at least 3*number_of_EMS_frames+4)
  2842. 18Bh    BYTE    number of UMB frame descriptors following
  2843. 18Ch 4N DWORDs    UMB frame descriptors
  2844.         each is 4 DWORDs giving physical page numbers for the four
  2845.           4K pages of a 16K EMS frame (00000000h if non-UMB page)
  2846. var    BYTE    number of EMS handle info records following
  2847.     16N BYTEs    EMS handle info records (see #0812)
  2848. ---version 1.10+ ---
  2849.     DWORD    realmode INT 67 vector (used by Windows to set breakpoints)
  2850.     DWORD    physical address of HMA page table values
  2851.     BYTE    number of free page entries following
  2852.      2N DWORDs    free page entries
  2853.         each is:
  2854.             DWORD    physical page number
  2855.             DWORD    number of consecutive physical pages
  2856.     BYTE    number of XMS handle info records following
  2857.         00h if memory manager does not emulate XMS or has real mode
  2858.           XMS code which can execute in the Windows environment
  2859.     12N BYTEs    XMS handle info records (see #0813)
  2860.     BYTE    number of free UMB info records following
  2861.      2N WORDs    free UMB info records
  2862.         each is:
  2863.             WORD    real mode start segment
  2864.             WORD    size in paragraphs
  2865. ---version 1.11---
  2866.      20 BYTEs    blank-padded maker name
  2867.      20 BYTEs    blank-padded product name
  2868.  
  2869. Format of EMS frame status record:
  2870. Offset    Size    Description    (Table 0810)
  2871.  00h    BYTE    frame type (see #0811)
  2872.  01h    BYTE    owner handle (00h/FFh = none) from frame including UMB
  2873.         index to UMB frame descriptors
  2874.  02h    WORD    logical page for frame, 7FFFh if none, FFFFh if non-EMS frame
  2875.  04h    BYTE    EMS physical page number (FFh for non-EMS = don't care???)
  2876.  05h    BYTE    flags for non-EMS frames (00h for EMS frame)
  2877.         bits 0,1 for first 4K, bits 2,3 for second 4K, etc:
  2878.           10: direct mapping (linear address = physical address)
  2879.           01: UMB mapping
  2880.  
  2881. Bitfields for EMS frame type:
  2882. Bit(s)    Description    (Table 0811)
  2883.  0    EMS frame
  2884.  1    (if EMS frame) in standard 64K page frame
  2885.  2    first 4K of frame is UMB
  2886.  3    second 4K of frame is UMB
  2887.  4    third 4K of frame is UMB
  2888.  5    last 4K of frame is UMB
  2889.  
  2890. Format of EMS handle info record:
  2891. Offset    Size    Description    (Table 0812)
  2892.  00h    BYTE    handle number (00h = system handle)
  2893.  01h    BYTE    flags
  2894.         bit 0: normal handle rather than system handle
  2895.         bit 2: ??? (set by some EMS managers)
  2896.  02h  8 BYTEs    EMS handle's name
  2897.  0Ah    WORD    number of 16K pages for handle
  2898.  0Ch    DWORD    physical address of page table entries forming page map
  2899. Note:    all values should be zero for the system handle if no large frame
  2900.       support is present
  2901.  
  2902. Format of XMS handle info record:
  2903. Offset    Size    Description    (Table 0813)
  2904.  00h    WORD    handle
  2905.  02h    WORD    flags
  2906.         bit 0: handle usable by Windows
  2907.             (already in use when Windows started if clear)
  2908.         bit 1: reserved (0)
  2909.  04h    DWORD    size in KB (may be zero, used only if flags bit 0 set)
  2910.  08h    DWORD    physical address (only if flags bit 0 set)
  2911. --------m-214402SF02-------------------------
  2912. INT 21 U - Memory Managers - GET MEMORY MANAGER VERSION
  2913.     AX = 4402h subfn 02h
  2914.     BX = file handle for device "EMMXXXX0"
  2915.     CX = 0002h (size of buffer in bytes)
  2916.     DS:DX -> buffer for memory manager version (see #0814)
  2917.         first byte must be 02h on entry
  2918. Return: CF clear if successful
  2919.         buffer filled
  2920.     CF set on error
  2921.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2922. Note:    this function is supported by Microsoft EMM386.EXE v4.45+ and
  2923.       CEMM v5.10+, and is intended for use by MS Windows as it starts up
  2924. SeeAlso: AX=4402h/SF=00h,AX=4402h"EMM386",INT 67/AH=3Fh
  2925.  
  2926. Format of memory manager version:
  2927. Offset    Size    Description    (Table 0814)
  2928.  00h    BYTE    major version
  2929.  01h    BYTE    minor version (binary)
  2930. --------m-214402-----------------------------
  2931. INT 21 U - Microsoft EMM386.EXE v4.45 - GET MEMORY MANAGER INFORMATION
  2932.     AX = 4402h
  2933.     BX = file handle for device "EMMXXXX0"
  2934.     CX = size of buffer in bytes (varies, see #0815)
  2935.     DS:DX -> buffer for returned data (see #0815)
  2936.         first byte must be set on entry to indicate desired data
  2937. Return: CF clear if successful
  2938.         buffer filled
  2939.     CF set on error
  2940.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2941. Notes:    an error is returned if the number of bytes to be read does not match
  2942.       the number of bytes returned for the specified data item
  2943.     this function is part of the interface which allows MS Windows to
  2944.       cooperate with memory managers
  2945. SeeAlso: AX=4402h/SF=00h,AX=4402h/SF=01h,AX=4402h/SF=02h,INT 67/AX=FFA5h
  2946.  
  2947. Format of EMM386.EXE data buffer:
  2948. Offset    Size    Description    (Table 0815)
  2949.  00h    BYTE    (call) function
  2950.         03h get ???
  2951.         04h get ???
  2952. ---function 03h---
  2953.  00h    WORD    ???
  2954.  02h    WORD    ???
  2955. ---function 04h---
  2956.  00h    WORD    segment of UMB containing EMM386 code/data
  2957.  02h    WORD    number of paragraphs of EMM386 code/data in UMB
  2958.  04h    WORD    ???
  2959. ----------214402-----------------------------
  2960. INT 21 U - IFSHLP.SYS - GET ENTRY POINT
  2961.     AX = 4402h
  2962.     BX = file handle for device "IFS$HLP$"
  2963.     CX = 0008h (size of buffer in bytes)
  2964.     DS:DX -> buffer for entry point record (see #0713 at AH=3Fh"IFSHLP")
  2965. Return: CF clear if successful
  2966.         buffer filled
  2967.     CF set on error
  2968.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2969. SeeAlso: AH=3Fh"IFSHLP"
  2970. --------D-214403-----------------------------
  2971. INT 21 - DOS 2+ - IOCTL - WRITE TO CHARACTER DEVICE CONTROL CHANNEL
  2972.     AX = 4403h
  2973.     BX = file handle referencing character device
  2974.     CX = number of bytes to write
  2975.     DS:DX -> data to write
  2976. Return: CF clear if successful
  2977.         AX = number of bytes actually written
  2978.     CF set on error
  2979.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2980. Notes:    format of data is driver-specific (see below for some specific cases)
  2981.     if the file handle refers to "4DOSSTAK", the 4DOS (v2.x-3.03)
  2982.       KEYSTACK.SYS driver will push the specified characters on the
  2983.       keyboard stack; similarly for "NDOSSTAK", the NDOS KEYSTACK.SYS
  2984.       driver will push the characters onto the keyboard stack
  2985. SeeAlso: AX=4400h,AX=4402h,AX=4405h,INT 2F/AX=122Bh,INT 2F/AX=D44Dh
  2986. SeeAlso: INT 2F/AX=D44Fh
  2987. --------c-214403-----------------------------
  2988. INT 21 - SMARTDRV.SYS v3.x only - IOCTL - CACHE CONTROL
  2989.     AX = 4403h
  2990.     BX = handle for device "SMARTAAR"
  2991.     CX = number of bytes to write
  2992.     DS:DX -> SMARTDRV control block (see #0817)
  2993. Return: CF clear if successful
  2994.         AX = number of bytes actually written
  2995.         0000h if control block too small for given command
  2996.     CF set on error
  2997.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  2998. Note:    NCache2 (from the Norton Utilities v8.0) attempts to support this
  2999.       interface, but does not do so correctly, often hanging the system;
  3000.       one should use the SmartDrive v4.x or NCache private interfaces
  3001.       (see INT 2F/AX=4A10h/BX=0000h,INT 2F/AX=FE00h/DI=4E55h)
  3002. SeeAlso: AX=4402h"SMARTDRV",INT 2F/AX=4A10h/BX=0000h
  3003.  
  3004. (Table 0816)
  3005. Values for SMARTDRV function code:
  3006.  00h    flush cache
  3007.  01h    flush and discard cache
  3008.  02h    disable caching (flushes and discards cache first)
  3009.  03h    enable caching
  3010.  04h    control write caching
  3011.  05h    set flushing tick count
  3012.  06h    lock cache contents
  3013.  07h    unlock cache contents
  3014.  08h    set flush-on-reboot flag
  3015.  09h    unused
  3016.  0Ah    control full-track caching
  3017.  0Bh    reduce cache size
  3018.  0Ch    increase cache size
  3019.  0Dh    set INT 13 chain address
  3020.  
  3021. Format of SMARTDRV control block:
  3022. Offset    Size    Description    (Table 0817)
  3023.  00h    BYTE    function code (see #0816)
  3024. ---functions 00h-03h,06h,07h---
  3025.  no additional fields
  3026. ---function 04h---
  3027.  01h    BYTE    write caching control action
  3028.         00h turn off write-through
  3029.         01h turn on write-through
  3030.         02h turn off write buffering (also flushes cache)
  3031.         03h turn on write buffering (also flushes cache)
  3032. ---function 05h---
  3033.  01h    WORD    number of timer ticks between cache flushes
  3034. ---function 08h---
  3035.  01h    BYTE    new flush-on-reboot flag (00h off, 01h on)
  3036. ---function 0Ah---
  3037.  01h    BYTE    full-track writes are
  3038.         00h not cached
  3039.         01h cached
  3040. ---functions 0Bh,0Ch---
  3041.  01h    WORD    number of 16K pages by which to increase/reduce cache size
  3042. ---function 0Dh---
  3043.  01h    DWORD    new address to which to chain on INT 13
  3044. Note:    the previous address is not preserved
  3045. --------d-214403-----------------------------
  3046. INT 21 - CD-ROM device driver - IOCTL OUTPUT
  3047.     AX = 4403h
  3048.     BX = file handle referencing character device for CD-ROM driver
  3049.     CX = number of bytes to write
  3050.     DS:DX -> control block (see #0818)
  3051. Return: CF clear if successful
  3052.         AX = number of bytes actually written
  3053.     CF set on error
  3054.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3055. SeeAlso: AX=4402h"CD-ROM",INT 2F/AX=0802h
  3056.  
  3057. Format of CR-ROM control block:
  3058. Offset    Size    Description    (Table 0818)
  3059.  00h    BYTE    function code
  3060.         00h eject disk
  3061.         01h lock/unlock door
  3062.         02h reset drive
  3063.         03h control audio channel
  3064.         04h write device control string
  3065.         05h close tray
  3066. ---functions 00h,02h,05h---
  3067.  no further fields
  3068. ---function 01h---
  3069.  01h    BYTE    lock function
  3070.         00h unlock door
  3071.         01h lock door
  3072. ---function 03h---
  3073.  01h    BYTE    input channel (0-3) for output channel 0
  3074.  02h    BYTE    volume for output channel 0
  3075.  03h    BYTE    input channel (0-3) for output channel 1
  3076.  04h    BYTE    volume for output channel 1
  3077.  05h    BYTE    input channel (0-3) for output channel 2
  3078.  06h    BYTE    volume for output channel 2
  3079.  07h    BYTE    input channel (0-3) for output channel 3
  3080.  08h    BYTE    volume for output channel 3
  3081. Note:    output channels 0 and 1 are left and right, 2 and 3 are left prime and
  3082.       right prime; a volume of 00h is off
  3083. ---function 04h---
  3084.  01h  N BYTEs    bytes to send directly to the CD-ROM drive without
  3085.           interpretation
  3086. --------d-214403-----------------------------
  3087. INT 21 - Brian Antoine Seagate ST-01 SCSI.SYS - IOCTL - EXECUTE COMMANDS
  3088.     AX = 4403h
  3089.     BX = handle for device "SCSITAPE"
  3090.     CX = number of bytes to write
  3091.     DS:DX -> SCSITAPE control block (see #0819)
  3092. Return: CF clear if successful
  3093.         AX = number of bytes actually written
  3094.     CF set on error
  3095.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3096. SeeAlso: AX=4405h"ST-01",INT 78/AH=10h
  3097.  
  3098. Format of SCSITAPE control block:
  3099. Offset    Size    Description    (Table 0819)
  3100.  00h    WORD    command type
  3101.         'F' Format (argument 1 = interleave, argument 2 = format type)
  3102.         'E' Erase
  3103.         'R' Rewind
  3104.         'L' Load
  3105.         'N' No Load
  3106.         'S' Space (argument 1 = count, argument 2 = type)
  3107.         'M' File Mark (argument 1 = count)
  3108.         'A' Reassign
  3109.  02h    WORD    argument 1
  3110.  04h    WORD    argument 2
  3111.  06h    WORD    segment of command buffer
  3112.  08h    WORD    offset of command buffer
  3113.  0Ah    WORD    length of command buffer
  3114. --------E-214403-----------------------------
  3115. INT 21 U - AI Architects - OS/x86??? - API
  3116.     AX = 4403h
  3117.     BX = handle for device "AIA_OS"
  3118.     CX = number of bytes to write (ignored)
  3119.     DS:DX -> 12-byte buffer (see #0820), first byte is command:
  3120.           81h installation check
  3121.           82h get API entry point
  3122.           84h uninstall
  3123. Return: CF clear if successful
  3124.         AX = number of bytes actually written
  3125.         DS:DX buffer filled
  3126.     CF set on error
  3127.         AX = error code (01h,05h,06h,0Ch,0Dh) (see #0960 at AH=59h)
  3128. Notes:    these functions are only available if the DOS extender was loaded as a
  3129.       device driver in CONFIG.SYS
  3130.     called by TKERNEL (a licensed version of AI Architects/Ergo OS/x86)
  3131. SeeAlso: INT 2F/AX=FBA1h/BX=0081h,INT 2F/AX=FBA1h/BX=0082h
  3132. Index:    installation check;OS/x86|entry point;OS/x86|uninstall;OS/x86
  3133.  
  3134. Format of buffer on return:
  3135. Offset    Size    Description    (Table 0820)
  3136.  00h  4 BYTEs    signature "IABH"
  3137. ---if function 81h---
  3138.  (no additional fields)
  3139. ---if function 82h---
  3140.  04h    DWORD    pointer to API entry point (see INT 2F/AX=FBA1h/BX=0082h)
  3141. ---if function 84h---
  3142.  04h    WORD    success indicator
  3143.  06h    WORD    segment of ???
  3144.  08h    WORD    segment of ??? memory block to free if nonzero
  3145.  0Ah    WORD    segment of ??? memory block to free if nonzero
  3146. --------V-214403-----------------------------
  3147. INT 21 - PGS1600.DEV - IOCTL - SET CONFIGURATION???
  3148.     AX = 4403h
  3149.     BX = file handle for device "PGS1600$"
  3150.     CX = 0018h (size of buffer)
  3151.     DS:DX -> configuration buffer (see #0778 at AX=4402h"PGS1600")
  3152. Return: CF clear if successful
  3153.         AX = number of bytes actually written
  3154.     CF set on error
  3155.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3156. Program: PGS1600.DEV is a device driver for the Cornerstone Technology PG1600
  3157.       display adapter, which provides a 1600x1200 monochrome display as
  3158.       well as one of two emulations, MDA or CGA.
  3159. SeeAlso: AX=4402h"PGS1600"
  3160. --------N-214403-----------------------------
  3161. INT 21 - PC/TCP IPCUST.SYS - RESET CONFIGURATION DATA READ POINTER
  3162.     AX = 4403h
  3163.     BX = file handle referencing device "$IPCUST"
  3164.     CX, DS:DX ignored
  3165. Return: CF clear if successful
  3166.         AX destroyed
  3167.     CF set on error
  3168.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3169. Notes:    there are a total of 378h bytes of configuration data for IPCUST.SYS
  3170.       version 2.05.     If less than the entire data is read or written,
  3171.       the next read/write continues where the previous one ended; this
  3172.       call and AX=4402h both reset the location at which the next
  3173.       operation starts to zero
  3174.     v2.1+ uses a new configuration method, but allows the installation
  3175.       of IPCUST.SYS for backward compatibility with other software which
  3176.       must read the PC/TCP configuration
  3177. SeeAlso: AH=3Fh"IPCUST",AH=40h"IPCUST",AX=4402h"IPCUST"
  3178. --------V-214403-----------------------------
  3179. INT 21 - Compaq AG1024.SYS - CPQ_MGES - IOCTL OUTPUT
  3180.     AX = 4403h
  3181.     BX = file handle referencing device "CPQ_MGES"
  3182.     DS:DX -> request packet (see #0821)
  3183.     CX ignored
  3184. Return: CF clear if successful
  3185.         AX destroyed
  3186.         data buffer filled (if applicable)
  3187.         first word of request packet set to number of bytes of data
  3188.           available (amount returned is smaller of this and requested
  3189.           amount)
  3190.     CF set on error
  3191.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3192. Program: AG1024.SYS is a device driver for the Advanced Graphics 1024 adapter
  3193. SeeAlso: AX=4403h"RGDI"
  3194.  
  3195. Format of Compaq AG1024.SYS request packet:
  3196. Offset    Size    Description    (Table 0821)
  3197.  00h    WORD    function
  3198.         0000h get ??? (26h bytes)
  3199.         0001h get ??? (36h bytes)
  3200.         0002h set ??? (same as returned by function 0001h)
  3201.         0003h get ??? (6 bytes)
  3202.         0004h get ???
  3203.         0005h get ???
  3204.         0006h get ??? (10h bytes)
  3205.         0007h set ??? (same as returned by function 0006h)
  3206. ---functions 00h-03h,06h,07h---
  3207.  02h    WORD    size of data buffer
  3208.  04h    DWORD    -> buffer for function's data
  3209.  ---functions 04h,05h---
  3210.  02h    WORD    ???
  3211.  04h    WORD    size of data buffer
  3212.  06h    DWORD    -> buffer to receive data
  3213. --------V-214403-----------------------------
  3214. INT 21 - Compaq AG1024.SYS - RGDI - IOCTL OUTPUT
  3215.     AX = 4403h
  3216.     BX = file handle referencing device "$$$$RGDI"
  3217.     DS:DX -> request packet (see #0822)
  3218.     CX ignored
  3219. Return: CF clear if successful
  3220.         AX destroyed
  3221.         data buffer filled (if applicable)
  3222.         first word of request packet set to number of bytes of data
  3223.           available (amount returned is smaller of this and requested
  3224.           amount)
  3225.     CF set on error
  3226.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3227. Program: AG1024.SYS is a device driver for the Advanced Graphics 1024 adapter
  3228. SeeAlso: AX=4402h"RGDI",AX=4403h"CPQ_MGES"
  3229.  
  3230. Format of Compaq AG1024.SYS request packet:
  3231. Offset    Size    Description    (Table 0822)
  3232.  00h    WORD    function
  3233.         0000h get entry points
  3234.         0001h get ???
  3235.  02h    DWORD    address of buffer for returned data
  3236. --------m-214403SF01-------------------------
  3237. INT 21 U - Qualitas 386MAX v6.01+ - TURN 386MAX OFF
  3238.     AX = 4403h subfn 01h
  3239.     BX = handle for device "386MAX$$"
  3240.     DS:DX -> BYTE 01h
  3241.     CX ignored
  3242. Return: DS:DX -> BYTE status (00h = successful)
  3243.     CF clear if successful
  3244.         AX destroyed
  3245.     CF set on error
  3246.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3247. Note:    this function will fail if any EMS or UMBs are in use
  3248. SeeAlso: AX=4403h/SF=02h,AX=4403h/SF=03h,AX=4403h/SF=05h
  3249. --------m-214403SF02-------------------------
  3250. INT 21 U - Qualitas 386MAX v6.01+ - TURN 386MAX ON
  3251.     AX = 4403h subfn 02h
  3252.     BX = handle for device "386MAX$$"
  3253.     DS:DX -> BYTE 02h
  3254.     CX ignored
  3255. Return: DS:DX -> BYTE status (00h = successful)
  3256.     CF clear if successful
  3257.         AX destroyed
  3258.     CF set on error
  3259.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3260. SeeAlso: AX=4403h/SF=01h,AX=4403h/SF=03h,AX=4403h/SF=05h
  3261. --------m-214403SF03-------------------------
  3262. INT 21 U - Qualitas 386MAX v6.01+ - SET STATE
  3263.     AX = 4403h subfn 03h
  3264.     BX = handle for device "386MAX$$"
  3265.     CX = number of bytes to copy (up to size of state buffer)
  3266.     DS:DX -> BYTE 03h followed by state buffer
  3267.           (see #0761 at AX=4402h"386MAX")
  3268. Return: CF clear if successful
  3269.         AX = number of bytes actually written
  3270.     CF set on error
  3271.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3272. Note:    the first byte of the buffer must be either 01h, 02h, or 03h
  3273.       (specifying the version of the state record) and the buffer must
  3274.       contain CX bytes AFTER the initial byte
  3275. SeeAlso: AX=4402h"386MAX"
  3276. --------m-214403SF05-------------------------
  3277. INT 21 U - Qualitas 386MAX v7.00+ - LIMIT AUTOMATIC ACTIVATION TO STD EMS CALLS
  3278.     AX = 4403h subfn 05h
  3279.     BX = handle for device "386MAX$$"
  3280.     DS:DX -> BYTE 05h
  3281.     CX ignored
  3282. Return: CF clear if successful
  3283.         AX destroyed
  3284.     CF set on error
  3285.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3286. Desc:    specifies that 386MAX will only shift from AUTO to ON mode on standard
  3287.       EMS calls INT 67/AH=40h-5Dh
  3288. SeeAlso: AX=4403h/SF=02h,AX=4403h/SF=03h,AX=4403h/SF=06h
  3289. --------m-214403SF06-------------------------
  3290. INT 21 U - Qualitas 386MAX v7.00+ - ALLOW AUTOMATIC ACTIVATION ON ANY INT 67
  3291.     AX = 4403h subfn 06h
  3292.     BX = handle for device "386MAX$$"
  3293.     DS:DX -> BYTE 06h
  3294.     CX ignored
  3295. Return: CF clear if successful
  3296.         AX destroyed
  3297.     CF set on error
  3298.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3299. Desc:    specified that 386MAX should shift from AUTO to ON mode on any INT 67
  3300.       call other than INT 67/AH=3Fh
  3301. SeeAlso: AX=4403h/SF=01h,AX=4403h/SF=03h,AX=4403h/SF=05h
  3302. --------n-214403-----------------------------
  3303. INT 21 U - PenDOS PENDEV.SYS - ???
  3304.     AX = 4403h
  3305.     BX = file handle for device "$$PENDOS" or "$$PD_REG"
  3306.     CX = size of buffer
  3307.     DS:DX -> buffer containing ???
  3308. Return: CF clear if successful
  3309.         buffer filled
  3310.     CF set on error
  3311.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3312. Program: A limited version of PenDOS by Communication Intelligence Corporation,
  3313.       which provides pen capability to keyboard-based programs, is bundled
  3314.       with IBM DOS 6.1
  3315. Note:    this call sets the WORD at offset 1Ah into the device driver request
  3316.       header used to call the driver to 0000h.
  3317. SeeAlso: AX=4402h"PENDEV.SYS"
  3318. --------D-214404-----------------------------
  3319. INT 21 - DOS 2+ - IOCTL - READ FROM BLOCK DEVICE CONTROL CHANNEL
  3320.     AX = 4404h
  3321.     BL = drive number (00h = default, 01h = A:, etc.)
  3322.     CX = number of bytes to read
  3323.     DS:DX -> buffer
  3324. Return: CF clear if successful
  3325.         AX = number of bytes actually read
  3326.     CF set on error
  3327.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3328. Note:    format of data is driver-specific
  3329. SeeAlso: AX=4402h,AX=4405h,INT 2F/AX=122Bh
  3330. --------k-214404-----------------------------
  3331. INT 21 - Stacker - GET DEVICE DRIVER ADDRESS AND SET VOLUME NUMBER
  3332.     AX = 4404h
  3333.     BL = drive number (00h = default, 01h = A:, etc.)
  3334.     CX = 0004h
  3335.     DS:DX -> DWORD buffer to receive device driver address
  3336. Return: buffer filled with pointer into Stacker device driver (see #1803):
  3337.       driver + 19h if Stacker Anywhere controls this drive
  3338.       driver + 1Ah if Stacker controls this drive
  3339.       unchanged else
  3340. Notes:    in addition to returning the address of the Stacker device driver,
  3341.       this call also sets the volume number at offset 58h in the device
  3342.       driver (see #1803 at INT 25/AX=CDCDh)
  3343.     Stacker Anywhere does not link its built-in device driver into
  3344.       the standard device driver chain, but it can be found via CDS/DPB
  3345.     this call can be used as an installation check for all versions of
  3346.       Stacker and Stacker Anywhere to avoid the INT 25 call
  3347. SeeAlso: AX=4408h,AX=440Eh,AH=52h,INT 25/AX=CDCDh
  3348. --------k-214404-----------------------------
  3349. INT 21 - Stacker - GET STACVOL FILE SECTORS
  3350.     AX = 4404h
  3351.     BL = drive number (0 is current drive)
  3352.     CX = byte count (i.e., 200h = 1 sector)
  3353.     DS:DX -> buffer (see #0823)
  3354. Return: Data Buffer contains the number of sectors requested from the
  3355.       STACVOL physical file for the drive specified.
  3356.  
  3357. Format of Stacker buffer:
  3358. Offset    Size    Description    (Table 0823)
  3359.  00h    WORD    01CDh
  3360.  02h    WORD    sector count
  3361.  04h    DWORD    number of starting sector
  3362.  08h    DWORD    far pointer to Data Buffer
  3363. --------k-214404-----------------------------
  3364. INT 21 - DUBLDISK.SYS v2.6 - GET INFO
  3365.     AX = 4404h
  3366.     BL = drive number of DoubleDisk drive (00h = default, 01h = A:, etc.)
  3367.     CX = number of bytes (000Ah-0014h, call ignored otherwise)
  3368.     DS:DX -> data record (see #0824)
  3369. Return: CF clear if successful
  3370.         AX = number of bytes read
  3371.     CF set on error
  3372.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3373. Program: DUBLDISK.SYS is the device driver portion of DoubleDisk, a disk
  3374.       expander by Vertisoft Systems, Inc.
  3375. Note:    the installation check for v2.6 consists of scanning memory for the
  3376.       signature "FAT 2.6  byte:", which is immediately followed by a data
  3377.       table (see #0825)
  3378. BUG:    VOPT (a disk optimizer by Golden Bow Software) assumes that any driver
  3379.       which returns the "correct" number of bytes when the first word of
  3380.       the buffer for the data record contains the signature value 4444h is
  3381.       DoubleDisk; a workaround is for the non-DoubleDisk driver to return
  3382.       no data if the signature is present
  3383. SeeAlso: AX=440Dh
  3384. Index:    installation check;DUBLDISK.SYS
  3385.  
  3386. Format of DUBLDISK data record:
  3387. Offset    Size    Description    (Table 0824)
  3388.  00h    WORD    (call) signature 4444h
  3389.  02h    BYTE    (call) function
  3390.             00h ???
  3391.             01h ???
  3392. ---function 00h---
  3393.  02h    BYTE    (ret) ???
  3394.  03h    BYTE    (ret) ???
  3395. ---function 01h---
  3396.  02h    WORD    (ret) 4444h
  3397.  04h    WORD    allocation unit size???
  3398.  06h    WORD    ???
  3399.  08h    WORD    ???
  3400.  0Ah    BYTE    ???
  3401.  
  3402. Format of DUBLDISK signature data table:
  3403. Offset    Size    Description    (Table 0825)
  3404.  00h  5 BYTEs    ???
  3405.  05h    BYTE    first drive number
  3406.  06h    BYTE    number of drives
  3407.  07h    ???
  3408. --------k-214404-----------------------------
  3409. INT 21 - DBLSPACE.BIN - IOCTL - FLUSH OR INVALIDATE INTERNAL CACHES
  3410.     AX = 4404h
  3411.     BL = drive number (00h = default, 01h = A:, etc)
  3412.     CX = 000Ah (size of DSPACKET structure)
  3413.     DS:DX -> DSPACKET structure (see #0826)
  3414. Return: CF clear if IOCTL successful -- check DSPACKET for actual status
  3415.         AX = number of bytes actually transferred
  3416.     CF set on error
  3417.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3418. SeeAlso: AX=4405h"DBLSPACE",INT 2F/AX=4A11h/BX=0000h
  3419.  
  3420. Format of DoubleSpace DSPACKET structure:
  3421. Offset    Size    Description    (Table 0826)
  3422.  00h    WORD    signature 444Dh ("DM")
  3423.  02h    BYTE    command code
  3424.         46h ('F') flush internal caches
  3425.         49h ('I') flush and invalidate internal caches
  3426.  03h    WORD    result code
  3427.         (ret) 4F4Bh ("OK") if successful, else unchanged
  3428.  05h  5 BYTEs    padding
  3429. --------k-214404-----------------------------
  3430. INT 21 - DBLSPACE.BIN v6.2 - IOCTL - GET ??? FOR SPECIFIED DRIVE
  3431.     AX = 4404h
  3432.     BL = drive number (00h = default, 01h = A:, etc)
  3433.     CX = size of DSPACKET structure (ignored in DOS 6.2)
  3434.     DS:DX -> DSPACKET structure (see #0827)
  3435. Return: CF clear if IOCTL successful -- check DSPACKET for actual status
  3436.         AX = number of bytes actually transferred
  3437.     CF set on error
  3438.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3439. SeeAlso: AX=4405h"DBLSPACE",INT 2F/AX=4A11h/BX=0000h
  3440.  
  3441. Format of DoubleSpace DSPACKET structure:
  3442. Offset    Size    Description    (Table 0827)
  3443.  00h    WORD    signature 444Dh ("DM")
  3444.  02h    BYTE    command code
  3445.         53h ('S') get ??? for specified drive
  3446.  03h    WORD    result code
  3447.         (ret) 4F4Bh ("OK") if successful, else unchanged
  3448.  05h    DWORD    (ret) pointer to 96-byte ??? data
  3449.  09h    DWORD    (ret) pointer to ??? data
  3450.  0Dh  3 BYTEs    reserved
  3451. --------k-214404-----------------------------
  3452. INT 21 U - DoubleTools v1.0 - GET ???
  3453.     AX = 4404h
  3454.     BL = drive number (00h = default, 01h = A:, etc)
  3455.     CX = 0006h
  3456.     DS:DX -> DoubleTools structure (see #0828)
  3457. Return: CF clear if IOCTL successful -- check DSPACKET for actual status
  3458.         AX = number of bytes actually transferred
  3459.     CF set on error
  3460.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3461. Note:    the Transporter device driver has the signature 55h 61h 50h 74h
  3462.       ("DaPt") twelve bytes after it beginning
  3463.  
  3464. Format of DoubleTools structure:
  3465. Offset    Size    Description    (Table 0828)
  3466.  00h    WORD    (call) signature 55h AAh
  3467.         (ret) signature 78h 70h ("xp")
  3468.  02h    WORD    (call) signature 52h 16h
  3469.         (ret) ???
  3470.  04h    WORD    (ret) segment of driver's DS (same as its PSP)
  3471. --------d-214404-----------------------------
  3472. INT 21 U - xDISK v3.31 - CONFIGURE
  3473.     AX = 4404h
  3474.     BL = drive number (00h = default, 01h = A:, etc)
  3475.     CX = 0047h (length of version string)
  3476.     DS:DX -> 79-byte buffer for version string and ???
  3477.     DS:0081h = commandline containing new switches for driver
  3478. Return: CF clear if successful
  3479.         AX = number of bytes actually transferred
  3480.     CF set on error
  3481.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3482. Program: xDISK is a shareware resizeable EMS RAMdisk by FM de Monasterio
  3483. SeeAlso: AX=4405h"xDISK",INT 2F/AH=DDh/BX=7844h"xDISK"
  3484. --------c-214404-----------------------------
  3485. INT 21 - COMBI-disk v1.13 - GET DATA RECORD
  3486.     AX = 4404h
  3487.     BL = drive number (00h = default, 01h = A:, etc)
  3488.     CX = 0032h (length of data packet)
  3489.     DS:DX -> buffer for data packet (see #0829)
  3490. Return: CF clear if successful
  3491.         AX = number of bytes actually transferred
  3492.     CF set on error
  3493.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3494. Program: COMBI-disk is a shareware combination cache and RAMdisk sharing a
  3495.       single pool of memory by Vadim V. Vlasov
  3496. Note:    the installation check consists of scanning the valid drives for one
  3497.       which returns a correctly-sized data packet with the proper
  3498.       signature in the first field
  3499. SeeAlso: AX=4405h"COMBI"
  3500. Index:    installation check;COMBI-disk
  3501.  
  3502. Format of COMBI-disk data packet:
  3503. Offset    Size    Description    (Table 0829)
  3504.  00h  6 BYTEs    ASCIZ signature "COMBI"
  3505.  06h    WORD    version (high byte = major, low = decimal minor version)
  3506.  08h    BYTE    current options (see below)
  3507.  09h    BYTE    sectors per allocation block
  3508.  0Ah    WORD    maximum buffer in KB
  3509.  0Ch    WORD    current buffer in KB (less than max if XMS memory being lent)
  3510.  0Eh    WORD    total number of allocation blocks
  3511.  10h    WORD    current number of allocation blocks
  3512.  12h    WORD    number of blocks being used by RAM disk
  3513.  14h    WORD    number of blocks being used by cache or unused
  3514.  16h    WORD    number of dirty cache blocks
  3515.  18h    WORD    number of blocks which could not be written out due to errors
  3516.  1Ah    WORD    total number of read requests
  3517.  1Ch    WORD    total number of sectors read
  3518.  1Eh    WORD    number of BIOS read requests (cache misses)
  3519.  20h    WORD    number of sectors read via BIOS (cache misses)
  3520.  22h    WORD    total number of write requests
  3521.  24h    WORD    total number of sectors written
  3522.  26h    WORD    number of BIOS write requests
  3523.  28h    WORD    number of sectors written via BIOS
  3524.  2Ah    WORD    number of RAM disk read requests
  3525.  2Ch    WORD    number of sectors read from RAM disk
  3526.  2Eh    WORD    number of RAM disk write requests
  3527.  30h    WORD    number of sectors written to RAM disk
  3528. --------d-214404-----------------------------
  3529. INT 21 - SFS v1.00 - GET CONFIGURATION INFORMATION
  3530.     AX = 4404h
  3531.     BL = drive number (00h = default, 01h = A:, etc)
  3532.     CX = 001Ah (length of data packet)
  3533.     DS:DX -> buffer for data packet (see #0830)
  3534. Return: CF clear if successful
  3535.         AX = number of bytes actually transferred
  3536.     CF set on error
  3537.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3538. Program: SFS (Secure FileSystem) is a shareware encrypting disk driver by
  3539.       Peter C. Gutmann
  3540. SeeAlso: AX=4405h"SFS"
  3541.  
  3542. Format of SFS data packet:
  3543. Offset    Size    Description    (Table 0830)
  3544.  00h  4 BYTEs    signature string "SFS1"
  3545.  04h    WORD    SFS unit number (0-based)
  3546.  06h    WORD    drive on which the SFS volume is mounted
  3547.  08h    DWORD    sector offset of logical volume from start of physical volume
  3548.         0 if logical volume = physical volume
  3549.  0Ch    WORD    flag: 00h = no disk mounted, 01h = disk mounted
  3550.  0Eh    WORD    flag: 00h read/write, 01h read-only
  3551.  10h    WORD    quick-unmount hotkey
  3552.         (high byte = shift state, low = scan code) (see #0005)
  3553.  12h    WORD    auto-unmount time in minutes, or 0000h if already expired, or
  3554.         FFFFh if not set
  3555.  14h    WORD    time in minutes remaining before auto-unmount
  3556.  16h    WORD    internal driver check code
  3557.         0000h no error
  3558.         0001h driver consistency check failed
  3559.         0002h unit consistency check failed
  3560.  18h    WORD    disk access mode
  3561.         0000h BIOS
  3562.         0001h IDE direct access
  3563.         0002h SCSI direct access
  3564. --------D-214405-----------------------------
  3565. INT 21 - DOS 2+ - IOCTL - WRITE TO BLOCK DEVICE CONTROL CHANNEL
  3566.     AX = 4405h
  3567.     BL = drive number (00h = default, 01h = A:, etc)
  3568.     CX = number of bytes to write
  3569.     DS:DX -> data to write
  3570. Return: CF clear if successful
  3571.         AX = number of bytes actually written
  3572.     CF set on error
  3573.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3574. Note:    format of data is driver-specific
  3575. SeeAlso: AX=4403h,AX=4404h,INT 2F/AX=122Bh
  3576. --------d-214405-----------------------------
  3577. INT 21 - Brian Antoine Seagate ST-01 SCSI.SYS - IOCTL - EXECUTE COMMANDS
  3578.     AX = 4405h
  3579.     BX = drive number (00h = default, 01h = A:, etc)
  3580.     CX = number of bytes to write
  3581.     DS:DX -> SCSIDISK control block (see also #0819 at AX=4403h"ST-01")
  3582. Return: CF clear if successful
  3583.         AX = number of bytes actually written
  3584.     CF set on error
  3585.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3586. SeeAlso: AX=4403h"ST-01"
  3587. --------k-214405-----------------------------
  3588. INT 21 U - DBLSPACE.BIN - IOCTL - FLUSH OR INVALIDATE INTERNAL CACHES
  3589.     AX = 4405h
  3590.     BL = drive number (00h = default, 01h = A:, etc)
  3591.     CX = 000Ah (size of DSPACKET structure)
  3592.     DS:DX -> DSPACKET structure (see #0831)
  3593. Return: CF clear if IOCTL successful -- check DSPACKET for actual status
  3594.         AX = number of bytes actually transferred
  3595.     CF set on error
  3596.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3597. Note:    this call is identical to the documented AX=4404h
  3598. SeeAlso: AX=4404h"DBLSPACE",INT 2F/AX=4A11h/BX=0000h
  3599.  
  3600. Format of DoubleSpace DSPACKET structure:
  3601. Offset    Size    Description    (Table 0831)
  3602.  00h    WORD    signature 444Dh ("DM")
  3603.  02h    BYTE    command code
  3604.         46h ('F') flush internal caches
  3605.         49h ('I') flush and invalidate internal caches
  3606.  03h    WORD    result code
  3607.         (ret) 4F4Bh ("OK") if successful, else unchanged
  3608.  05h  5 BYTEs    padding
  3609. --------d-214405-----------------------------
  3610. INT 21 U - xDISK v3.31 - ???
  3611.     AX = 4405h
  3612.     BL = drive number (00h = default, 01h = A:, etc)
  3613.     CX = number of bytes to write
  3614.     DS:DX -> buffer containing version string
  3615.     ???
  3616. Return: CF clear if successful
  3617.         AX = number of bytes actually transferred
  3618.     CF set on error
  3619.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3620. Program: xDISK is a shareware resizeable EMS RAMdisk by FM de Monasterio
  3621. SeeAlso: AX=4404h"xDISK",INT 2F/AH=DDh/BX=7844h"xDISK"
  3622. --------d-214405-----------------------------
  3623. INT 21 - COMBI-disk v1.13 - CONTROL COMBI-disk
  3624.     AX = 4405h
  3625.     BL = drive number (00h = default, 01h = A:, etc) for RAM disk
  3626.     CX = number of bytes to write
  3627.     DS:DX -> buffer containing command packet (see #0833)
  3628. Return: CF clear if successful
  3629.         AX = number of bytes actually transferred
  3630.     CF set on error
  3631.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3632. SeeAlso: AX=4404h"COMBI"
  3633.  
  3634. (Table 0832)
  3635. Values for COMBI-disk command code:
  3636.  80h    flush cache
  3637.  81h    change options byte
  3638.  82h    shrink memory
  3639.  83h    expand memory
  3640.  84h    get dirty block information
  3641.  85h    reset write errors
  3642.  86h    reset counters
  3643.  
  3644. Format of COMBI-disk command packet:
  3645. Offset    Size    Description    (Table 0833)
  3646.  00h    WORD    version
  3647.  02h    BYTE    command code (see #0832)
  3648. ---command code 80h---
  3649.  no additional fields
  3650. ---command code 81h---
  3651.  03h    BYTE    new options byte (see #0834)
  3652. ---command code 82h---
  3653.  03h    WORD    number of KB to release
  3654. ---command code 83h---
  3655.  03h    WORD    number of KB to expand
  3656. ---command code 84h---
  3657.  03h    DWORD    -> buffer for block info (see #0835)
  3658. ---command code 85h---
  3659.  03h    DWORD    block ID
  3660. ---command code 86h---
  3661.  03h    BYTE    which counters to reset
  3662.         bit 0: hard disk read counts
  3663.         bit 1: hard disk write counts
  3664.         bit 2: RAM disk read/write counts
  3665. Note:    multiple commands may be placed in a single packet by stringing
  3666.       together as many command/argument pairs as desired
  3667.  
  3668. Bitfields for COMBI-disk options byte:
  3669. Bit(s)    Description    (Table 0834)
  3670.  0    cache off
  3671.  1    cache frozen
  3672.  2    write caching enabled
  3673.  3    delayed writing disabled
  3674.  5    fix memory allocation (no XMS lending)
  3675.  6    no 'sector not found' error
  3676.  
  3677. Format of COMBI-disk block info:
  3678. Offset    Size    Description    (Table 0835)
  3679.  00h    DWORD    block ID
  3680.  04h    BYTE    bitmask of valid sectors in block
  3681.  05h    BYTE    bitmask of dirty sectors in block
  3682.  06h    BYTE    last error returned by BIOS
  3683.  07h    BYTE    number of errors
  3684. --------D-214405-----------------------------
  3685. INT 21 - SFS v1.00 - DRIVER CONTROL
  3686.     AX = 4405h
  3687.     BL = drive number (00h = default, 01h = A:, etc)
  3688.     CX = number of bytes to write
  3689.     DS:DX -> data to write (see #0837)
  3690. Return: CF clear if successful
  3691.         AX = number of bytes actually written
  3692.     CF set on error
  3693.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3694. Program: SFS (Secure FileSystem) is a shareware encrypting disk driver by
  3695.       Peter C. Gutmann
  3696. SeeAlso: AX=4404h"SFS"
  3697.  
  3698. (Table 0836)
  3699. Values for SFS control function:
  3700.  00h    "PACKET_SET_DISKINFO"     set disk parameters
  3701.  01h    "PACKET_SET_KEYINFO"     set keying information
  3702.  02h    "PACKET_SET_READONLY"     select read/write or read-only
  3703.  03h    "PACKET_SET_DRIVENO"     set drive number to mount
  3704.  04h    "PACKET_SET_MOUNTSTATUS" set mount status
  3705.  05h    "PACKET_SET_UNMOUNT"     set/clear quick-unmount hotkey
  3706.  06h    "PACKET_SET_TIMEOUT"     set/clear auto-unmount timeout
  3707.  
  3708. Format of SFS control data packet:
  3709. Offset    Size    Description    (Table 0837)
  3710.  00h    WORD    signature 4330h ('C0')
  3711.  02h    WORD    function (see #0836)
  3712. ---function 00h---
  3713.  04h    WORD    sector size in bytes
  3714.  06h    BYTE    sectors per cluster
  3715.  07h    WORD    number of boot sectors
  3716.  09h    BYTE    number of copies of FAT
  3717.  0Ah    WORD    size of root directory in entries
  3718.  0Ch    WORD    number of sectors on disk, 16-bit
  3719.  0Eh    BYTE    media descriptor byte
  3720.  0Fh    WORD    sectors per FAT
  3721.  11h    WORD    sectors per track
  3722.  13h    WORD    number of heads
  3723.  15h    DWORD    number of hidden sectors
  3724.  19h    DWORD    number of sectors on disk, 32-bit
  3725. ---function 01h---
  3726.  04h 20 BYTEs    master IV for encrypted disk
  3727.  18h 64 BYTEs    NDC/SHS keying information
  3728. ---function 02h---
  3729.  04h    WORD    read-only state: 00h read-only, 01h read/write
  3730. ---function 03h---
  3731.  04h    WORD    drive number (see #0838)
  3732.  06h    DWORD    sector offset of logical volume from start of physical volume
  3733.         0 if logical volume = physical volume
  3734. ---function 04h---
  3735.  04h    WORD    mount status (00h unmounted, 01h mounted)
  3736. ---function 05h---
  3737.  04h    WORD    hotkey (high byte = shift state, low byte = scan code or 00h)
  3738.         (see #0005)
  3739.         0000h to disable hotkey
  3740. ---function 06h---
  3741.  04h    WORD    timeout in minutes before automatic unmount
  3742.         0000h to disable auto-unmount
  3743. Notes:    the data for function 00h corresponds to a DOS BPB (see AH=53h)
  3744.     functions 00h, 01h, and 03h automatically unmount the encrypted drive
  3745.     unmounting a drive with function 04h also destroys the encryption
  3746.       information in the driver and forces all dirty buffers to be flushed
  3747.  
  3748. Bitfields for SFS drive number:
  3749. Bit(s)    Description    (Table 0838)
  3750.  15-12    drive access mode
  3751.     0000 BIOS access
  3752.     0001 direct IDE access
  3753.     0010 direct SCSI access
  3754. ---if BIOS access---
  3755.  11-8    unused (0)
  3756.  7-0    BIOS drive number
  3757. ---if IDE access---
  3758.  11-8    unused (0)
  3759.  7-0    IDE drive number
  3760. ---if SCSI access---
  3761.  11-8    SCSI host number
  3762.  7-4    SCSI target ID
  3763.  3-0    SCSI logical unit number
  3764. --------D-214406-----------------------------
  3765. INT 21 - DOS 2+ - IOCTL - GET INPUT STATUS
  3766.     AX = 4406h
  3767.     BX = file handle
  3768. Return: CF clear if successful
  3769.         AL = input status
  3770.         00h not ready (device) or at EOF (file)
  3771.         FFh ready
  3772.     CF set on error
  3773.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3774. Note:    files may not register as being at EOF if positioned there by AH=42h
  3775. SeeAlso: AX=4407h,INT 2F/AX=122Bh
  3776. --------D-214407-----------------------------
  3777. INT 21 - DOS 2+ - IOCTL - GET OUTPUT STATUS
  3778.     AX = 4407h
  3779.     BX = file handle
  3780. Return: CF clear if successful
  3781.         AL = input status
  3782.         00h not ready
  3783.         FFh ready
  3784.     CF set on error
  3785.         AX = error code (01h,05h,06h,0Dh) (see #0960 at AH=59h)
  3786. Note:    for DOS 2+, files are always ready for output, even if the disk is
  3787.       full or no media is in the drive
  3788. SeeAlso: AX=4406h,INT 2F/AX=122Bh
  3789. --------D-214408-----------------------------
  3790. INT 21 - DOS 3.0+ - IOCTL - CHECK IF BLOCK DEVICE REMOVABLE
  3791.     AX = 4408h
  3792.     BL = drive number (00h = default, 01h = A:, etc)
  3793. Return: CF clear if successful
  3794.         AX = media type (0000h removable, 0001h fixed)
  3795.     CF set on error
  3796.         AX = error code (01h,0Fh) (see #0960 at AH=59h)
  3797. Note:    in addition to the normal operation, if Stacker is installed, this
  3798.       call also sets the volume number at offset 58h in the Stacker
  3799.       device driver (except under DR DOS 3.41-5.0, which do not pass
  3800.       through this call to the driver; use AX=440Eh instead)
  3801.       (see AX=4404h"Stacker",AX=440Eh,INT 25/AX=CDCDh)
  3802. SeeAlso: AX=4400h,AX=4404h"Stacker",AX=4409h,INT 2F/AX=122Bh
  3803. --------D-214409-----------------------------
  3804. INT 21 - DOS 3.1+ - IOCTL - CHECK IF BLOCK DEVICE REMOTE
  3805.     AX = 4409h
  3806.     BL = drive number (00h = default, 01h = A:, etc)
  3807. Return: CF clear if successful
  3808.         DX = device attribute word
  3809.         bit 15: drive is SUBSTituted
  3810.         bit 12: drive is remote
  3811.         bit  9: direct I/O not allowed
  3812.     CF set on error
  3813.         AX = error code (01h,0Fh) (see #0960 at AH=59h)
  3814. Note:    on local drives, DX bits not listed above are the attribute word from
  3815.       the device driver header (see #0933 at AH=52h); for remote drives,
  3816.       the other bits appear to be undefined for DOS versions prior to 5.0
  3817.       (they are all cleared in DOS 5+)
  3818.     checking whether DX=0800h on return appears to be a fairly reliable
  3819.       method for detecting Microsoft's RAMDRIVE, though not for other
  3820.       ramdisks (there appears to be no simple yet foolproof method for
  3821.       detecting ramdisks, although the presence of only a single copy of
  3822.       the FAT and only a single head on non-removable devices is a fairly
  3823.       good indicator)
  3824. SeeAlso: AX=4400h,AX=4408h,AX=440Ah,INT 2F/AX=122Bh
  3825. --------D-21440A-----------------------------
  3826. INT 21 - DOS 3.1+ - IOCTL - CHECK IF HANDLE IS REMOTE
  3827.     AX = 440Ah
  3828.     BX = handle
  3829. Return: CF clear if successful
  3830.         DX = attribute word (as stored in SFT)
  3831.         bit 15: set if remote
  3832.         bit 14: date/time not set on close
  3833.     CF set on error
  3834.         AX = error code (01h,06h) (see #0960 at AH=59h)
  3835. Notes:    if file is remote, Novell Advanced NetWare 2.0 returns the number of
  3836.       the file server on which the handle is located in CX
  3837.     DR DOS 3.41 and 5.0 clear all bits of DX except bit 15
  3838. SeeAlso: AX=4400h,AX=4409h,AH=52h,INT 2F/AX=122Bh
  3839. --------D-21440B-----------------------------
  3840. INT 21 - DOS 3.1+ - IOCTL - SET SHARING RETRY COUNT
  3841.     AX = 440Bh
  3842.     CX = pause between retries (default 1)
  3843.     DX = number of retries (default 3)
  3844. Return: CF clear if successful
  3845.     CF set on error
  3846.         AX = error code (01h) (see #0960 at AH=59h)
  3847. Notes:    delay is dependent on processor speed (value in CX specifies number of
  3848.       64K-iteration empty loops to execute)
  3849.     if DX=0000h on entry, the retry count is left unchanged
  3850. SeeAlso: AH=52h,INT 2F/AX=1224h,INT 2F/AX=122Bh
  3851. --------D-21440C-----------------------------
  3852. INT 21 - DOS 3.2+ - IOCTL - GENERIC CHARACTER DEVICE REQUEST
  3853.     AX = 440Ch
  3854.     BX = device handle
  3855.     CH = category code (see #0839)
  3856.     CL = function number (see #0840)
  3857.     DS:DX -> parameter block (see #0841,#0842,#0843,#0844,#0845,#0846)
  3858.     SI = parameter to pass to driver (European MS-DOS 4.0, OS/2 comp box)
  3859.     DI = parameter to pass to driver (European MS-DOS 4.0, OS/2 comp box)
  3860. Return: CF set on error
  3861.         AX = error code (see #0960 at AH=59h)
  3862.     CF clear if successful
  3863.         DS:DX -> iteration count if CL=65h
  3864.         SI = returned value (European MS-DOS 4.0, OS/2 comp box)
  3865.         DI = returned value (European MS-DOS 4.0, OS/2 comp box)
  3866. Note:    DR DOS 3.41 and 5.0 return error code 16h on CL=45h,65h if the device
  3867.       does not support a retry counter
  3868. SeeAlso: AX=440Dh,INT 2F/AX=0802h,INT 2F/AX=122Bh,INT 2F/AX=14FFh
  3869. SeeAlso: INT 2F/AX=1A01h
  3870.  
  3871. (Table 0839)
  3872. Values for IOCTL category code:
  3873.  00h    unknown (DOS 3.3+)
  3874.  01h    COMn: (DOS 3.3+)
  3875.  03h    CON (DOS 3.3+)
  3876.  05h    LPTn:
  3877.  9Eh    Media Access Control driver (STARLITE)
  3878.  00h-7Fh reserved for Microsoft
  3879.  80h-FFh reserved for OEM/user-defined
  3880.  
  3881. (Table 0840)
  3882. Values for generic character IOCTL function:
  3883.  00h    MAC driver Bind (STARLITE) (see #0841)
  3884.  45h    set iteration (retry) count (see #0842)
  3885.  4Ah    select code page (see #0843)
  3886.  4Ch    start code-page preparation (see #0844)
  3887.  4Dh    end code-page preparation (see #0845)
  3888.  5Fh    set display information (DOS 4.0+) (see #0846)
  3889.  65h    get iteration (retry) count
  3890.  6Ah    query selected code page (see #0843)
  3891.  6Bh    query prepare list (see #0847)
  3892.  7Fh    get display information (DOS 4.0+) (see #0846)
  3893. Note:    bit assignments for function code:
  3894.         bit 7: set to ignore if unsupported, clear to return error
  3895.         bit 6: set if passed to driver, clear if intercepted by DOS
  3896.         bit 5: set if queries data from device, clear if sends command
  3897.         bits 4-0: subfunction
  3898.  
  3899. Format of parameter block for function 00h:
  3900. Offset    Size    Description    (Table 0841)
  3901.  00h  8 BYTEs    ASCIZ signature "STARMAC"
  3902.  08h    WORD    version
  3903.  0Ah    WORD    flags
  3904.         bit 0: media requires connect or listen request before use
  3905.         bit 1: network is a LAN (broadcast/multicast supported)
  3906.         bit 2: point-to-point network
  3907.  0Ch    WORD    handle for use with MAC driver's private interface (filled in
  3908.         by MAC driver)
  3909.  0Eh    WORD    context
  3910.  10h    WORD    approximate speed in KB/sec (filled in by MAC driver)
  3911.  12h    WORD    approximate cost in cents per hour (filled in by MAC driver)
  3912.  14h    WORD    maximum packet size in bytes (filled in by MAC driver)
  3913.  16h    WORD    addressing format (filled in by MAC driver)
  3914.         0000h general addressing
  3915.         0001h Ethernet addressing
  3916.         0002h Token Ring addressing
  3917.         0003h Token Bus addressing
  3918.  18h    DWORD    Send entry point (filled in by MAC driver)
  3919.  1Ch    DWORD    RegisterEventHandler entry point (filled in by MAC driver)
  3920.  20h    DWORD    SetPacketFilter entry point (filled in by MAC driver)
  3921.  24h    DWORD    UnBind entry point (filled in by MAC driver)
  3922.  
  3923. Format of parameter block for function 45h:
  3924. Offset    Size    Description    (Table 0842)
  3925.  00h    WORD    number of times output is attempted before driver assumes
  3926.           device is busy
  3927.  
  3928. Format of parameter block for functions 4Ah and 6Ah:
  3929. Offset    Size    Description    (Table 0843)
  3930.  00h    WORD    length of data
  3931.  02h    WORD    code page ID (see #1040 at INT 21/AX=6602h)
  3932.  04h 2N BYTEs    DCBS (double byte character set) lead byte range
  3933.           start/end for each of N ranges (DOS 4.0)
  3934.     WORD    0000h  end of data (DOS 4.0)
  3935.  
  3936. Format of parameter block for function 4Ch:
  3937. Offset    Size    Description    (Table 0844)
  3938.  00h    WORD    flags
  3939.         DISPLAY.SYS = 0000h
  3940.         PRINTER.SYS bit 0 clear to prepare downloaded font, set to
  3941.             prepare cartridge selection
  3942.  02h    WORD    length of remainder of parameter block
  3943.  04h    WORD    number of code pages following
  3944.  06h  N WORDs    code page 1,...,N
  3945.  
  3946. Format of parameter block for function 4Dh:
  3947. Offset    Size    Description    (Table 0845)
  3948.  00h    WORD    length of data
  3949.  02h    WORD    code page ID (see #1040 at INT 21/AX=6602h)
  3950.  
  3951. Format of parameter block for functions 5Fh and 7Fh:
  3952. Offset    Size    Description    (Table 0846)
  3953.  00h    BYTE    level (0 for DOS 4.x-6.0)
  3954.  01h    BYTE    reserved (0)
  3955.  02h    WORD    length of following data (14)
  3956.  04h    WORD    control flags
  3957.         bit 0 set for blink, clear for intensity
  3958.         bits 1-15 reserved
  3959.  06h    BYTE    mode type (1=text, 2=graphics)
  3960.  07h    BYTE    reserved (0)
  3961.  08h    WORD    colors
  3962.         0000h = monochrome
  3963.         else N bits per pixel
  3964.  0Ah    WORD    pixel columns
  3965.  0Ch    WORD    pixel rows
  3966.  0Eh    WORD    character columns
  3967.  10h    WORD    character rows
  3968.  
  3969. Format of parameter block for function 6Bh:
  3970. Offset    Size    Description    (Table 0847)
  3971.  00h    WORD    length of following data
  3972.  02h    WORD    number of hardware code pages
  3973.  04h  N WORDs    hardware code pages 1,...,N
  3974.     WORD    number of prepared code pages
  3975.       N WORDs    prepared code pages 1,...,N
  3976. --------d-21440C-----------------------------
  3977. INT 21 - Greg Shenaut ASPITAPE.SYS - INTERFACE
  3978.     AX = 440Ch
  3979.     BX = device handle
  3980.     CH = category code
  3981.         07h tape (ASPITAPE.SYS)
  3982.     CL = function
  3983.         01h "mtop" - perform tape operation
  3984.         02h "mtget" - get tape status
  3985.         03h ignore end-of-tape errors
  3986.         04h enable end-of-tape errors
  3987.     DS:DX -> parameter block (see #0848,#0849)
  3988. Return: CF set on error
  3989.         AX = error code (see #0960 at AH=59h)
  3990.     CF clear if successful
  3991.         DS:DX -> data block
  3992. Notes:    This device driver is a simple DOS interface to the Adaptec Advanced
  3993.       SCSI Programming Interface (ASPI).  It provides the following device
  3994.       names as access to the SCSI tape, 'RMTx' (rewind on close) and
  3995.       'NRMTx' (NO rewind on close) where x can go from 0 to 3.  There may
  3996.       also be the following names 'MTx' and 'NMTx' which default to 1024
  3997.       byte blocks.    The names may also have a '$' appended to try and make
  3998.       them unique from file names of 'RMT0' etc.
  3999.     once opend these devices must be put into RAW mode
  4000. SeeAlso: AX=4402h"ASPI"
  4001.  
  4002. Format of ASPITAPE.SYS mtop parameter block:
  4003. Offset    Size    Description    (Table 0848)
  4004.  00h    WORD    operation code
  4005.         00h "MTWEOF" - write an end-of-file record
  4006.         01h "MTFSF" - forward space file
  4007.         02h "MTBSF" - backward space file
  4008.         03h "MTFSR" - forward space record
  4009.         04h "MTBSR" - backward space record
  4010.         05h "MTREW" - rewind
  4011.         06h "MTOFFL" - rewind and unload
  4012.         07h "MTNOP" - perform TEST UNIT READY
  4013.  02h    DWORD    repetition count
  4014.  
  4015. Format of ASPITAPE.SYS mtget parameter block:
  4016. Offset    Size    Description    (Table 0849)
  4017.  00h    BYTE    ASPI host ID
  4018.  01h    BYTE    SCSI target ID
  4019.  02h    BYTE    SCSI logical unit number
  4020.  03h    BYTE    device parameters
  4021.         bit 0: drive must use fixed-block read and write
  4022.         bit 7: drive is an ASPI device
  4023.  04h    BYTE    current device state (see #0850)
  4024.  05h    BYTE    unit number within driver
  4025.  06h    WORD    fixed block blocksize
  4026.  08h    BYTE    last SCSI status
  4027.  09h    BYTE    last SCSI sense key
  4028.  0Ah    WORD    last SCSI opcode (packed) (see #0851)
  4029.  0Ch    WORD    residual bytes from SCSI opcode
  4030.  
  4031. Bitfields for ASPITAPE.SYS current device state:
  4032. Bit(s)    Description    (Table 0850)
  4033.  0    device currently opened in buffered mode
  4034.  1    drive currently opened in nonbuffered mode
  4035.  2    rewind drive on last close
  4036.  3    drive has been written on
  4037.  4    drive has been read from
  4038.  5    next read will return 0 bytes
  4039.  6    EOM will resemble EOF
  4040.  7    drive may be busy rewinding
  4041.  
  4042. Bitfields for SCSI opcode:
  4043. Bit(s)    Description    (Table 0851)
  4044.  0-7    SCSI operation (SCSI packet byte 0)
  4045.  8-10    SCSI flags (SCSI packet byte 1)
  4046.  11-12    ASPI "Direction Bits" (ASPI SRB byte 3)
  4047. --------D-21440D-----------------------------
  4048. INT 21 - DOS 3.2+ - IOCTL - GENERIC BLOCK DEVICE REQUEST
  4049.     AX = 440Dh
  4050.     BL = drive number (00h=default,01h=A:,etc)
  4051.     CH = category code (see #0852)
  4052.     CL = minor code (function) (see #0853)
  4053.     DS:DX -> (DOS) parameter block (see #0854,#0856,#0857,#0858,#0859)
  4054.     SI:DI -> (OS/2 comp box) parameter block (see #0860,#0862,#0863,#0864)
  4055. Return: CF set on error
  4056.         AX = error code (01h,02h) (see #0960 at AH=59h)
  4057.     CF clear if successful
  4058.         DS:DX -> data block if CL=60h or CL=61h
  4059. Notes:    DOS 4.01 seems to ignore the high byte of the number of directory
  4060.       entries in the BPB for diskettes.
  4061.     functions 46h and 66h undocumented in DOS 4.x, documented for DOS 5+
  4062.     the DUBLDISK.SYS v2.6 driver only supports minor codes 60h and 67h
  4063.     DR DOS 3.41-6.0 only support minor codes 40h-42h and 60h-62h; all
  4064.       other minor codes return error code 16h
  4065.     some PCMCIA calls reportedly appear to be dangerous for MS-DOS versions
  4066.       prior to 5.0
  4067.     minor code 60h normally produces no I/O except with AutoMount=1 for
  4068.       DBLSPACE/DRVSPACE
  4069. SeeAlso: AX=440Ch,AH=69h,INT 2F/AX=0802h,INT 2F/AX=122Bh
  4070.  
  4071. (Table 0852)
  4072. Values for block device IOCTL category code:
  4073.  08h    disk drive
  4074.  00h-7Fh reserved for Microsoft
  4075.  80h-FFh reserved for OEM/user-defined
  4076.  
  4077. (Table 0853)
  4078. Values for generic block IOCTL minor code:
  4079.  00h    (OS/2)    \ used to lock/unlock a drive
  4080.  01h    (OS/2)    /
  4081.  40h    set device parameters (see #0854)
  4082.  41h    write logical device track (see #0856)
  4083.  42h    format and verify logical device track (see #0857)
  4084.  46h    (DOS 4.0+) set volume serial number (see #0859,AH=69h)
  4085.  47h    (DOS 4.0+) set access flag (see #0860)
  4086.  48h    (Enh. Disk Drive Spec) set media lock state (see #0861,INT 13/AH=45h)
  4087.  49h    (Enh. Disk Drive Spec) eject media in drive (see INT 13/AH=49h)
  4088.  4Ah    (MS-DOS 7.0) lock drive (allow direct write access)
  4089.  50h    (PCMCIA) attribute memory write
  4090.  51h    (PCMCIA) common memory write
  4091.  52h    (PCMCIA) force media change (DOS 5+ ???) (see #0862)
  4092.  53h    (PCMCIA) erase drive
  4093.  54h    (PCMCIA) erase media
  4094.  56h    (PCMCIA) set erase status callback
  4095.  57h    (PCMCIA) append Card Information Structure (CIS) tuple
  4096.  58h    (PCMCIA) erase CIS tuples
  4097.  60h    get device parameters (see #0854)
  4098.  61h    read logical device track (see #0856)
  4099.  62h    verify logical device track (see #0858)
  4100.  66h    (DOS 4.0+) get volume serial number (see #0859,AH=69h)
  4101.  67h    (DOS 4.0+) get access flag (see #0860)
  4102.  68h    (DOS 5.0+) sense media type (see #0863)
  4103.  6Ah    (MS-DOS 7.0) unlock drive (disable direct write access)
  4104.  70h    (PCMCIA) attribute memory read
  4105.  73h    (PCMCIA) get memory media information (DOS 5+ ???) (see #0864)
  4106.  76h    (PCMCIA) get erase status callback
  4107.  77h    (PCMCIA) get first Card Information Structure (CIS) tuple
  4108.  78h    (PCMCIA) get next CIS tuple
  4109.  7Fh    (PCMCIA) get ??? information (see #0865,#0866)
  4110.  
  4111. Format of parameter block for functions 40h, 60h:
  4112. Offset    Size    Description    (Table 0854)
  4113.  00h    BYTE    special functions
  4114.         bit 0 set if function to use current BPB, clear if Device
  4115.               BIOS Parameter Block field contains new default BPB
  4116.         bit 1 set if function to use track layout fields only
  4117.             must be clear if CL=60h
  4118.         bit 2 set if all sectors in track same size (should be set)
  4119.         bits 3-7 reserved (MS-DOS, Novell DOS 7)
  4120.         bit 5: skip head settling time (WinDOS 2.11)
  4121.         bit 6: format access flag (WinDOS 2.11)
  4122.  01h    BYTE    device type (see #0855)
  4123.  02h    WORD    device attributes
  4124.         bit 0 set if nonremovable medium
  4125.         bit 1 set if door lock ("changeline") supported
  4126.         bits 2-15 reserved
  4127.  04h    WORD    number of cylinders
  4128.  06h    BYTE    media type
  4129.         for 1.2M drive
  4130.             00h 1.2M disk (default)
  4131.             01h 320K/360K disk
  4132.         F8h for DUBLDISK.SYS v2.6 expanded drives
  4133.         always 00h for other drive types
  4134.  07h 31 BYTEs    device BPB (see #0950 at AH=53h), bytes after BPB offset 1Eh
  4135.           omitted; final six bytes only transferred on function 40h
  4136.           with BYTE 00h bit 0 set for MS-DOS 5.0
  4137. ---function 40h only---
  4138.  26h    WORD    number of sectors per track (start of track layout field)
  4139.         (maximum 63)
  4140.  28h  N word pairs: number,size of each sector in track
  4141.  
  4142. (Table 0855)
  4143. Values for device type:
  4144.  00h    320K/360K disk
  4145.  01h    1.2M disk
  4146.  02h    720K disk
  4147.  03h    single-density 8-inch disk
  4148.  04h    double-density 8-inch disk
  4149.  05h    fixed disk
  4150.  06h    tape drive
  4151.  07h    (DOS 3.3+) other type of block device, normally 1.44M floppy
  4152.  08h    read/write optical disk
  4153.  09h    (DOS 5+) 2.88M floppy
  4154.  
  4155. Format of parameter block for functions 41h, 61h:
  4156. Offset    Size    Description    (Table 0856)
  4157.  00h    BYTE    special functions (reserved, must be zero)
  4158.  01h    WORD    number of disk head
  4159.  03h    WORD    number of disk cylinder
  4160.  05h    WORD    number of first sector to read/write
  4161.  07h    WORD    number of sectors
  4162.  09h    DWORD    transfer address
  4163.  
  4164. Format of parameter block for function 42h:
  4165. Offset    Size    Description    (Table 0857)
  4166.  00h    BYTE    reserved, must be zero (DOS <3.2)
  4167.           bit 0=0: format/verify track
  4168.             1: format status call (DOS 3.2+), don't actually format
  4169.           bit 1: format multiple tracks, require additional WORD
  4170.               (hard disks only)
  4171.           bits 2-7 reserved, must be zero
  4172.         value on return (DOS 3.3+):
  4173.           00h    specified tracks, sectors/track supported by BIOS
  4174.           01h    function not supported by BIOS
  4175.           02h    specified tracks, sectors/track not allowed for drive
  4176.           03h    no disk in drive
  4177.  01h    WORD    number of disk head
  4178.  03h    WORD    number of disk cylinder
  4179. ---BYTE 00h bit 1 set---
  4180.  05h    WORD    number of tracks to format
  4181.  
  4182. Format of parameter block for function 62h:
  4183. Offset    Size    Description    (Table 0858)
  4184.  00h    BYTE    reserved, must be zero (DOS <3.2)
  4185.           bit 0=0: verify single track
  4186.             1: verify multiple tracks
  4187.           bits 1-7 reserved, must be zero
  4188.         value on return (DOS 3.3+):
  4189.           00h    specified tracks, sectors/track supported by BIOS
  4190.           01h    function not supported by BIOS
  4191.           02h    specified tracks, sectors/track not allowed for drive
  4192.           03h    no disk in drive
  4193.  01h    WORD    number of disk head
  4194.  03h    WORD    number of disk cylinder
  4195.  05h    WORD    number of tracks to verify (equivalent to 255 or fewer sectors)
  4196.  
  4197. Format of parameter block for functions 46h, 66h:
  4198. Offset    Size    Description    (Table 0859)
  4199.  00h    WORD    (call) info level (should be 0000h)
  4200.  02h    DWORD    disk serial number (binary)
  4201.  06h 11 BYTEs    volume label or "NO NAME    "
  4202.  11h  8 BYTEs    filesystem type "FAT12     " or "FAT16   "
  4203.           (generally CL=66h only, but MS-DOS 5.0 will write the
  4204.           given filesystem type to the disk)
  4205.  
  4206. Format of parameter block for functions 47h, 67h:
  4207. Offset    Size    Description    (Table 0860)
  4208.  00h    BYTE    special-function field (must be zero)
  4209.  01h    BYTE    disk-access flag, nonzero if access allowed by driver
  4210.  
  4211. Format of parameter block for function 48h:
  4212. Offset    Size    Description    (Table 0861)
  4213.  00h    BYTE    (call) locking operation
  4214.         00h lock media in drive
  4215.         01h unlock media
  4216.         02h get locking status
  4217.  01h    BYTE    (ret) drive's lock status
  4218.  
  4219. Format of parameter block for function 52h:
  4220.  00h    BYTE    (call) unused???    (Table 0862)
  4221.         (ret) 00h if flash/ATA drive but no card inserted
  4222.             unchanged otherwise
  4223. Notes:    the absense of a flash card should be tested by checking the DOS error
  4224.       code rather than the returned byte
  4225.     the parameter byte is cleared to 00h erroneously by the Award
  4226.       PCDISK.EXE v1.02c PCMCIA/ATA driver if no ATA card is inserted
  4227.       (bug corrected in PCDISK.EXE v1.02h and later)
  4228.     not supported by the SystemSoft ATADRV.EXE and the Phoenix PCMATA.SYS
  4229.       PCMCIA/ATA drivers
  4230.  
  4231. Format of parameter block for function 68h:
  4232. Offset    Size    Description    (Table 0863)
  4233.  00h    BYTE    01h for default media type, 00h for any other media type
  4234.         (see also INT 13/AH=20h"Compaq")
  4235.  01h    BYTE    02h for 720K, 07h for 1.44M, 09h for 2.88M
  4236.  
  4237. Format of parameter block for function 73h:
  4238. Offset    Size    Description    (Table 0864)
  4239.  00h    BYTE    ???
  4240.         00h ATA card inserted ???
  4241.         80h ATA card not inserted ???
  4242.  01h    BYTE    length of parameter block ???
  4243.         apparently always 40h
  4244.  02h    BYTE    ???
  4245.         00h ATA card not inserted ???
  4246.         0Dh ATA card inserted ???
  4247.  03h  2 BYTEs    ??? (apparently always 00h)
  4248.  05h    BYTE    drive number (0=first) ???
  4249.  06h    BYTE    total number of drives ???
  4250.  07h    BYTE    ???
  4251.         00h ATA card not inserted ???
  4252.         01h ATA card inserted ???
  4253.  08h 17 BYTEs    ???
  4254.  19h    BYTE    ???
  4255.         00h ATA card not inserted ???
  4256.         01h ATA card inserted ???
  4257.  1Ah    BYTE    ??? (apparently always 01h)
  4258.  1Bh    BYTE    ???
  4259.         00h ATA card not inserted ???
  4260.         01h ATA card inserted ???
  4261.  1Ch  2 BYTEs    ??? (apparently always 0015h)
  4262.  1Eh  2 BYTEs    ???
  4263.  20h  2 BYTEs    ??? (apparently always 0110h)
  4264.  22h 15 BYTEs    ???
  4265.  31h  2 BYTEs    ??? (apparently always 7000h)
  4266.  33h 11 BYTEs    driver signature
  4267.         "AWARD PDISK" for Award PCDISK.EXE PCMCIA/ATA driver
  4268.         "MS-BIOS    " for HP 200LX generic ATA driver
  4269.  3Eh  2 BYTEs    ???
  4270. Notes:    parameter structure possibly depends on driver
  4271.     this function is not supported by the SystemSoft ATADRV.EXE and the
  4272.       Phoenix PCMATA.SYS PCMCIA/ATA drivers
  4273.  
  4274. Format of parameter block for function 7Fh for SystemSoft ATADRV.EXE:
  4275. Offset    Size    Description    (Table 0865)
  4276.  00h    DWORD    -> unknown location within driver
  4277. Note:    function supported by the SystemSoft ATADRV.EXE PCMCIA/ATA driver
  4278.       but not by the Award PCDISK.EXE PCMCIA/ATA driver
  4279. SeeAlso: #0866
  4280.  
  4281. Format of parameter block for function 7Fh for Phoenix PCMATA.SYS:
  4282. Offset    Size    Description    (Table 0866)
  4283.  00h  8 BYTEs    ???
  4284. Note:    this function supported by the Phoenix PCMATA.SYS PCMCIA/ATA driver
  4285.       but not by the Award PCDISK.EXE PCMCIA/ATA driver
  4286. SeeAlso: #0865
  4287. --------D-21440E-----------------------------
  4288. INT 21 - DOS 3.2+ - IOCTL - GET LOGICAL DRIVE MAP
  4289.     AX = 440Eh
  4290.     BL = drive number (00h=default,01h=A:,etc)
  4291. Return: CF set on error
  4292.         AX = error code (01h,0Fh) (see #0960 at AH=59h)
  4293.     CF clear if successful
  4294.         AL = 00h block device has only one logical drive assigned
  4295.          1..26 the last letter used to reference the drive (1=A:,etc)
  4296. Notes:    DR DOS 3.41-5.0 DRIVER.SYS does not support drive mapping and thus
  4297.       always returns AL=00h
  4298.     in addition to the normal operation, if Stacker is installed, this
  4299.       call also sets the volume number at offset 58h in the Stacker
  4300.       device driver (DR DOS 3.41-5.0 only; use AX=4408h otherwise)
  4301.       (see AX=4404h"Stacker",INT 25/AX=CDCDh)
  4302. SeeAlso: AX=4408h,AX=440Fh,INT 2F/AX=122Bh
  4303. --------D-21440F-----------------------------
  4304. INT 21 - DOS 3.2+ - IOCTL - SET LOGICAL DRIVE MAP
  4305.     AX = 440Fh
  4306.     BL = physical drive number (00h=default,01h=A:,etc))
  4307. Return: CF set on error
  4308.         AX = error code (01h,0Fh) (see #0960 at AH=59h)
  4309.     CF clear if successful
  4310.         drive now responds to next logical drive number
  4311. Notes:    maps logical drives to physical drives, similar to DOS's treatment of
  4312.       a single physical floppy drive as both A: and B:
  4313.     DR DOS 3.41-5.0 DRIVER.SYS does not support drive mapping and thus
  4314.       always returns an error on this function
  4315. SeeAlso: AX=440Eh,INT 2F/AX=122Bh
  4316. --------D-214410-----------------------------
  4317. INT 21 - DOS 5+ - IOCTL - QUERY GENERIC IOCTL CAPABILITY (HANDLE)
  4318.     AX = 4410h
  4319.     BX = handle for device
  4320.     CH = category code (see #0839)
  4321.     CL = function code (see #0840)
  4322. Return: CF clear if successful
  4323.         AX = 0000h    specified IOCTL function is supported
  4324.     CF set on error
  4325.         AL = 01h    IOCTL capability not available
  4326. Note:    a program which wishes to use Generic IOCTL calls beyond those in the
  4327.       standard DOS 3.2 set may use this call first to see whether a
  4328.       particular call is supported
  4329. SeeAlso: AX=440Ch,AX=440Dh,AX=4411h
  4330. --------d-214410BXFFFF-----------------------
  4331. INT 21 U - NewSpace - ENABLE DRIVER
  4332.     AX = 4410h
  4333.     BX = FFFFh
  4334. Program: NewSpace is a TSR by Isogon Corporation which automatically compresses
  4335.       all files as they are written and decompresses them as they are read
  4336. Note:    compressed files are not accessible unless the driver is enabled
  4337. SeeAlso: AX=4411h/BX=FFFFh
  4338. --------D-214411-----------------------------
  4339. INT 21 - DOS 5+ - IOCTL - QUERY GENERIC IOCTL CAPABILITY (DRIVE)
  4340.     AX = 4411h
  4341.     BL = drive number
  4342.     CH = category code (see #0852)
  4343.     CL = function code (see #0853)
  4344. Return: CF clear if successful
  4345.         AX = 0000h    specified IOCTL function is supported
  4346.     CF set on error
  4347.         AL = 01h    IOCTL capability not available
  4348. Note:    a program which wishes to use Generic IOCTL calls beyond those in the
  4349.       standard DOS 3.2 set may use this call first to see whether a
  4350.       particular call is supported
  4351. SeeAlso: AX=440Ch,AX=440Dh,AX=4410h
  4352. --------d-214411BXFFFF-----------------------
  4353. INT 21 U - NewSpace - DISABLE DRIVER
  4354.     AX = 4411h
  4355.     BX = FFFFh
  4356. Program: NewSpace is a TSR by Isogon Corporation which automatically compresses
  4357.       all files as they are written and decompresses them as they are read
  4358. Note:    compressed files are not accessible unless the driver is enabled
  4359. SeeAlso: AX=4410h/BX=FFFFh
  4360. --------O-214412-----------------------------
  4361. INT 21 O - DR DOS 5.0-6.0 - DETERMINE DOS TYPE
  4362.     AX = 4412h
  4363.     CF set
  4364. Return: CF set if not DR DOS
  4365.         AX = error code (see #0960 at AH=59h)
  4366.     CF clear if DR DOS
  4367.         DX = AX = version code (see #0868)
  4368. Note:    this obsolete call, which is no longer supported in Novell DOS 7, is
  4369.       identical to AX=4452h
  4370. SeeAlso: AX=4452h
  4371. --------d-214412BXFFFF-----------------------
  4372. INT 21 U - NewSpace - INSTALLATION CHECK???
  4373.     AX = 4412h
  4374.     BX = FFFFh
  4375. Return: AX = PSP segment of NewRes (resident driver for NewSpace)
  4376.     BX:DX -> ???
  4377.     CX = ???
  4378. SeeAlso: AX=4411h/BX=FFFFh
  4379. --------d-214413BXFFFF-----------------------
  4380. INT 21 U - NewSpace - GET ???
  4381.     AX = 4413h
  4382.     BX = FFFFh
  4383. Return: AX = code segment of NewRes (resident driver for NewSpace)
  4384.     BX = offset of ???
  4385. SeeAlso: AX=4412h/BX=FFFFh
  4386. --------O-214414-----------------------------
  4387. INT 21 OU - DR DOS 5.0-6.0 - SET GLOBAL PASSWORD
  4388.     AX = 4414h
  4389.     DS:DX -> password string (blank-padded to 8 characters)
  4390. Desc:    Specify the master password for accessing files.
  4391. Note:    this obsolete call, which is no longer supported in Novell DOS 7, is
  4392.       identical to AX=4454h
  4393. SeeAlso: AX=4454h
  4394. --------d-214414BXFFFF-----------------------
  4395. INT 21 U - NewSpace - DEBUGGING DUMP
  4396.     AX = 4414h
  4397.     BX = FFFFh
  4398. Return: debugging dump written to X:\NEWSPACE.SMP
  4399. SeeAlso: AX=4413h/BX=FFFFh,AX=44FFh/BX=FFFFh
  4400. --------O-2144-------------------------------
  4401. INT 21 OU - DR DOS 5.0-6.0 - HISTORY BUFFER, SHARE, AND HILOAD CONTROL
  4402.     AH = 44h
  4403.     AL = 16h to 18h
  4404. Note:    these obsolete subfunctions (which are no longer supported in Novell
  4405.       DOS 7) are identical to AX=4456h through 4458h
  4406. SeeAlso: AX=4456h,AX=4457h,AX=4458h
  4407. --------O-214451-----------------------------
  4408. INT 21 - Concurrent DOS v3.2+ - INSTALLATION CHECK
  4409.     AX = 4451h
  4410. Return: CF set if not Concurrent DOS
  4411.         AX = error code (see #0960 at AH=59h)
  4412.     CF clear if successful
  4413.         AH = single-user/multiuser nature
  4414.         10h single-user
  4415.             AL = operating system version ID (see #0868)
  4416.         14h multiuser
  4417.             AL = operating system version ID (see #0867)
  4418. Notes:    as of Concurrent DOS/XM 5.0 (possibly earlier), the version is stored
  4419.       in the environment variable VER
  4420.     use this function if you are looking for multiuser capabilities,
  4421.       AX=4452h for single-user
  4422.     this function should never return the single-user values
  4423. SeeAlso: AX=4452h,AX=4459h
  4424.  
  4425. (Table 0867)
  4426. Values for Digital Research operating system version ID:
  4427.  32h    Concurrent PC DOS 3.2
  4428.  41h    Concurrent DOS 4.1
  4429.  50h    Concurrent DOS/XM 5.0 or Concurrent DOS/386 1.1
  4430.  60h    Concurrent DOS/XM 6.0 or Concurrent DOS/386 2.0
  4431.  62h    Concurrent DOS/XM 6.2 or Concurrent DOS/386 3.0
  4432.  66h    DR Multiuser DOS 5.1
  4433.  67h    Concurrent DOS 5.1
  4434. --------O-214452-----------------------------
  4435. INT 21 - DR DOS 3.41+ - DETERMINE DOS TYPE/GET DR DOS VERSION
  4436.     AX = 4452h ("DR")
  4437.     CF set
  4438. Return: CF set if not DR DOS
  4439.         AX = error code (see #0960 at AH=59h)
  4440.     CF clear if DR DOS
  4441.         AX = version code
  4442.         AH = single-user/multiuser nature
  4443.         10h single-user
  4444.             AL = operating system version ID (see #0868)
  4445.         14h multiuser
  4446.             AL = operating system version ID (see #0867)
  4447.         DX modified (see note)
  4448. Notes:    the DR DOS version is stored in the environment variable VER
  4449.     use this function if looking for single-user capabilities, AX=4451h
  4450.       if looking for multiuser; this call should never return multiuser
  4451.       values
  4452.     in DR DOS 3.41-6.0, DX=AX on return; for Novell DOS 7, DH=AH but DL=00h
  4453.       (reportedly, DH=00h when booting NWDOS7 from installation disks)
  4454.     Novell DOS 7 returns error code 0001h if SETVER 255.x is in effect for
  4455.       the calling program
  4456. SeeAlso: AX=4412h,AX=4451h,AX=4459h
  4457.  
  4458. (Table 0868)
  4459. Values for Digital Research operating system version ID:
  4460.  60h    DOS Plus
  4461.  63h    DR DOS 3.41
  4462.  64h    DR DOS 3.42
  4463.  65h    DR DOS 5.00
  4464.  67h    DR DOS 6.00
  4465.  70h    PalmDOS
  4466.  71h    DR DOS 6.0 March 1993 "business update"
  4467.  72h    Novell DOS 7.0
  4468. --------O-214454-----------------------------
  4469. INT 21 U - DR DOS 3.41+ - SET GLOBAL PASSWORD
  4470.     AX = 4454h
  4471.     DS:DX -> password string (blank-padded to 8 characters)
  4472. Desc:    Specify the master password for accessing files.
  4473. SeeAlso: AX=4303h,AX=4414h
  4474. --------O-214456-----------------------------
  4475. INT 21 U - DR DOS 5.0+ - HISTORY BUFFER CONTROL
  4476.     AX = 4456h
  4477.     DL = control flags (see #0869)
  4478. Return: AL = previous value of state flags (see #0870)
  4479. Note:    DR DOS 6.0 only checks bit 0 and ignores the rest of DL
  4480. SeeAlso: #0871
  4481.  
  4482. Bitfields for control flags:
  4483. Bit(s)    Description    (Table 0869)
  4484.  0    whose buffer: 0=application, 1=COMMAND.COM
  4485. ---Novell DOS 7---
  4486.  1    toggle HISTORY usage
  4487.  2    toggle INSERT state
  4488. Note:    only one bit at a time may be used
  4489.  
  4490. Bitfields for state flags:
  4491. Bit(s)    Description    (Table 0870)
  4492.  0    HISTORY buffer enabled
  4493.  1    INSERT enabled
  4494.  2-5    unused
  4495.  7    whose buffer: 0=application, 1=COMMAND.COM
  4496. --------O-214457-----------------------------
  4497. INT 21 U - DR DOS 5.0+ - SHARE/HILOAD CONTROL
  4498.     AX = 4457h
  4499.     DH = subfunction
  4500.         00h enable/disable SHARE
  4501.         DL = 00h disable
  4502.            = 01h enable
  4503.            else Return: AX = ???
  4504.         01h get HILOAD status
  4505.         Return: AX = status
  4506.                 0000h off
  4507.                 0001h on
  4508.         02h set HILOAD status
  4509.         DL = new state (00h off, 01h on)
  4510.         Return: AX = ???
  4511.         other
  4512.         Return: AX = ???
  4513. Note:    This was seen called by COMMAND.COM of DR DOS 6.0; it does not seem
  4514.       to be supported by Novell DOS 7
  4515. SeeAlso: AX=4457h/DX=FFFFh
  4516. --------O-214457DXFFFF-----------------------
  4517. INT 21 U - DR DOS 6.0 - GET SHARE STATUS
  4518.     AX = 4457h
  4519.     DX = FFFFh
  4520. Return: AX = SHARE status
  4521. SeeAlso: INT 2F/AX=1000h
  4522. --------O-214458-----------------------------
  4523. INT 21 U - DR DOS 5.0+ internal - GET POINTER TO INTERNAL VARIABLE TABLE
  4524.     AX = 4458h
  4525. Return: ES:BX -> internal variable table (see #0871,#0872)
  4526.     AX = ??? (0B50h for DR DOS 5.0, 0A56h for DR DOS 6.0, 0FE4h for
  4527.           Novell DOS 7)
  4528. SeeAlso: AX=4452h
  4529.  
  4530. Format of DR DOS 5.0-6.0 internal variable table:
  4531. Offset    Size    Description    (Table 0871)
  4532.  00h    WORD    ???
  4533.  02h    WORD    segment of ???
  4534.  04h    WORD    offset within DOS data segment of history control structure
  4535.           for COMMAND.COM history buffer (see #0873)
  4536.  06h    WORD    offset within DOS data segment of history control structure
  4537.           for application history buffer (see #0873)
  4538.  08h    BYTE    initial history state flags (see #0870)
  4539.  09h  2 BYTEs    ???
  4540.  0Bh    WORD    KB of extended memory at startup
  4541.  0Dh    BYTE    number of far jump entry points
  4542.  0Eh    WORD    segment containing far jumps to DR DOS entry points (see #0874)
  4543.  10h    WORD    (only if kernel loaded in HMA) offset in HMA of first free HMA
  4544.           memory block (see #0875) or 0000h if none; segment is FFFFh
  4545.  12h    WORD    pointer to segment of environment variables set in CONFIG,
  4546.           or 0000h if already used
  4547. ---DR DOS 6.0---
  4548.  14h    WORD    (only if kernel loaded in HMA) offset in HMA of first used HMA
  4549.         memory block (see #0875) or 0000h if none; segment is FFFFh
  4550.  16h  8 BYTEs    ???
  4551.  1Eh    WORD    offset in DOS data segment of full COUNTRY.SYS filename
  4552.  20h  8 BYTEs    ???
  4553.  28h    WORD    offset in DOS data segment of SHARE hook table
  4554.  2Ah  2 BYTEs    ???
  4555.  2Ch    WORD    offset in DOS data segment of far pointer to INT 2F/AX=1000h
  4556.           handler
  4557. Note:    the segment used for the DR DOS 6.0 CONFIG environment variables
  4558.       (excluding COMSPEC, VER and OS) is only useful for programs/drivers
  4559.       called from CONFIG.SYS. The word is set to zero later when the area
  4560.       is copied to the COMMAND.COM environment space.  This allows
  4561.       CONFIG.SYS to pass information to AUTOEXEC.BAT.
  4562.  
  4563. Format of Novell DOS 7 internal variable table:
  4564. Offset    Size    Description    (Table 0872)
  4565.  00h    ???
  4566.  1Eh    WORD    offset of COUNTRY.SYS filename
  4567.  42h 16 DWORDs    pointers to ??? entry points
  4568.     ???
  4569.  
  4570. Format of history control structure:
  4571. Offset    Size    Description    (Table 0873)
  4572.  00h    WORD    segment of buffer
  4573.  02h    WORD    size of buffer in bytes
  4574.  04h    WORD    ???
  4575.  
  4576. Format of kernel entry jump table for DR DOS 5.0-6.0:
  4577. Offset    Size    Description    (Table 0874)
  4578.  00h  5 BYTEs    far jump to kernel entry point for CP/M CALL 5
  4579.  05h  5 BYTEs    far jump to kernel entry point for INT 20
  4580.  0Ah  5 BYTEs    far jump to kernel entry point for INT 21
  4581.  0Fh  5 BYTEs    far jump to kernel entry point for INT 22 (RETF)
  4582.  14h  5 BYTEs    far jump to kernel entry point for INT 23 (RETF)
  4583.  19h  5 BYTEs    far jump to kernel entry point for INT 24
  4584.  1Eh  5 BYTEs    far jump to kernel entry point for INT 25
  4585.  23h  5 BYTEs    far jump to kernel entry point for INT 26
  4586.  28h  5 BYTEs    far jump to kernel entry point for INT 27
  4587.  2Dh  5 BYTEs    far jump to kernel entry point for INT 28
  4588.  32h  5 BYTEs    far jump to kernel entry point for INT 2A (IRET)
  4589.  37h  5 BYTEs    far jump to kernel entry point for INT 2B (IRET)
  4590.  3Ch  5 BYTEs    far jump to kernel entry point for INT 2C (IRET)
  4591.  41h  5 BYTEs    far jump to kernel entry point for INT 2D (IRET)
  4592.  46h  5 BYTEs    far jump to kernel entry point for INT 2E (IRET)
  4593.  4Bh  5 BYTEs    far jump to kernel entry point for INT 2F
  4594. Notes:    all of these entry points are indirected through this jump table
  4595.       to allow the kernel to be relocated into high memory while leaving
  4596.       the actual entry addresses in low memory for maximum compatibility
  4597.     some of these entry points (22h,23h,24h,2Eh,2Fh) are replaced as soon
  4598.       as COMMAND.COM is loaded, and return immediately to the caller, some
  4599.       returning an error code (the original handler for INT 2F returns
  4600.       AL=03h [fail]).
  4601.  
  4602. Format of HMA Memory Block (DR DOS 6.0 kernel loaded in HMA):
  4603. Offset    Size    Description    (Table 0875)
  4604.  00h    WORD    offset of next HMA Memory Block (0000h if last block)
  4605.  02h    WORD    size of this block in bytes (at least 10h)
  4606.  04h    BYTE    type of HMA Memory Block (interpreted by MEM)
  4607.         00h system
  4608.         01h KEYB
  4609.         02h NLSFUNC
  4610.         03h SHARE
  4611.         04h TaskMAX
  4612.         05h COMMAND
  4613.  05h    var    TSR (or system) code and data. DR DOS TSR's, such as KEYB,
  4614.           hooks interrupts using segment FFFEh instead FFFFh.
  4615. --------O-214459-----------------------------
  4616. INT 21 - DR MultiUser DOS 5.0 - API
  4617.     AX = 4459h
  4618.     CL = function (see #3145 at INT E0"CP/M")
  4619.     DS,DX = parameters
  4620. Notes:    DR DOS 5.0 and Novell DOS 7 return CF set and AX=0001h
  4621.     this API is also available on INT E0
  4622. SeeAlso: AX=4452h,INT E0"CP/M"
  4623. --------N-2144E0-----------------------------
  4624. INT 21 U - Sun PC-NFS - API???
  4625.     AX = 44E0h
  4626.     DS:DX -> ???
  4627.     SS:BP -> stack frame (see #0876)
  4628. Return: ???
  4629. Note:    this function is also supported by Beame&Whiteside's BWPCNFS shim; the
  4630.       description presented here was derived from that shim
  4631.  
  4632. Format of PC-NFS stack frame:
  4633. Offset    Size    Description    (Table 0876)
  4634.  00h    WORD    -> previous stack frame
  4635.  02h    DWORD    return address
  4636. --------d-2144FFBXFFFF-----------------------
  4637. INT 21 U - NewSpace - ???
  4638.     AX = 44FFh
  4639.     BX = FFFFh
  4640.     DX = ???
  4641. Program: NewSpace is a TSR by Isogon Corporation which automatically compresses
  4642.       all files as they are written and decompresses them as they are read
  4643. SeeAlso: AX=4414h/BX=FFFFh
  4644. --------D-2145-------------------------------
  4645. INT 21 - DOS 2+ - "DUP" - DUPLICATE FILE HANDLE
  4646.     AH = 45h
  4647.     BX = file handle
  4648. Return: CF clear if successful
  4649.         AX = new handle
  4650.     CF set on error
  4651.         AX = error code (04h,06h) (see #0960 at AH=59h)
  4652. Notes:    moving file pointer for either handle will also move it for the other,
  4653.       because both will refer to the same system file table
  4654.     for DOS versions prior to 3.3, file writes may be forced to disk by
  4655.       duplicating the file handle and closing the duplicate
  4656. SeeAlso: AH=3Dh,AH=46h
  4657. --------D-2146-------------------------------
  4658. INT 21 - DOS 2+ - "DUP2", "FORCEDUP" - FORCE DUPLICATE FILE HANDLE
  4659.     AH = 46h
  4660.     BX = file handle
  4661.     CX = file handle to become duplicate of first handle
  4662. Return: CF clear if successful
  4663.     CF set on error
  4664.         AX = error code (04h,06h) (see #0960 at AH=59h)
  4665. Notes:    closes file with handle CX if it is still open
  4666.     DOS 3.30 hangs if BX=CX on entry
  4667.     moving file pointer for either handle will also move it for the other,
  4668.       because both will refer to the same system file table
  4669. SeeAlso: AH=3Dh,AH=45h
  4670. --------D-2147-------------------------------
  4671. INT 21 - DOS 2+ - "CWD" - GET CURRENT DIRECTORY
  4672.     AH = 47h
  4673.     DL = drive number (00h = default, 01h = A:, etc)
  4674.     DS:SI -> 64-byte buffer for ASCIZ pathname
  4675. Return: CF clear if successful
  4676.         AX = 0100h (undocumented)
  4677.     CF set on error
  4678.         AX = error code (0Fh) (see #0960 at AH=59h)
  4679. Notes:    the returned path does not include a drive or the initial backslash
  4680.     many Microsoft products for Windows rely on AX being 0100h on success
  4681.     under the FlashTek X-32 DOS extender, the buffer pointer is in DS:ESI
  4682. SeeAlso: AH=19h,AH=3Bh,AH=71h,INT 15/AX=DE25h
  4683. --------D-2148-------------------------------
  4684. INT 21 - DOS 2+ - ALLOCATE MEMORY
  4685.     AH = 48h
  4686.     BX = number of paragraphs to allocate
  4687. Return: CF clear if successful
  4688.         AX = segment of allocated block
  4689.     CF set on error
  4690.         AX = error code (07h,08h) (see #0960 at AH=59h)
  4691.         BX = size of largest available block
  4692. Notes:    DOS 2.1-6.0 coalesces free blocks while scanning for a block to
  4693.       allocate
  4694.     .COM programs are initially allocated the largest available memory
  4695.       block, and should free some memory with AH=49h before attempting any
  4696.       allocations
  4697.     under the FlashTek X-32 DOS extender, EBX contains a protected-mode
  4698.       near pointer to the allocated block on a successful return
  4699. SeeAlso: AH=49h,AH=4Ah,AH=58h,AH=83h
  4700. --------D-2149-------------------------------
  4701. INT 21 - DOS 2+ - FREE MEMORY
  4702.     AH = 49h
  4703.     ES = segment of block to free
  4704. Return: CF clear if successful
  4705.     CF set on error
  4706.         AX = error code (07h,09h) (see #0960 at AH=59h)
  4707. Notes:    apparently never returns an error 07h, despite official docs; DOS 2.1+
  4708.       code contains only an error 09h exit
  4709.     DOS 2.1-6.0 does not coalesce adjacent free blocks when a block is
  4710.       freed, only when a block is allocated or resized
  4711.     the code for this function is identical in DOS 2.1-6.0 except for
  4712.       calls to start/end a critical section in DOS 3.0+
  4713. SeeAlso: AH=48h,AH=4Ah
  4714. --------D-214A-------------------------------
  4715. INT 21 - DOS 2+ - RESIZE MEMORY BLOCK
  4716.     AH = 4Ah
  4717.     BX = new size in paragraphs
  4718.     ES = segment of block to resize
  4719. Return: CF clear if successful
  4720.     CF set on error
  4721.         AX = error code (07h,08h,09h) (see #0960 at AH=59h)
  4722.         BX = maximum paragraphs available for specified memory block
  4723. Notes:    under DOS 2.1-6.0, if there is insufficient memory to expand the block
  4724.       as much as requested, the block will be made as large as possible
  4725.     DOS 2.1-6.0 coalesces any free blocks immediately following the block
  4726.       to be resized
  4727. SeeAlso: AH=48h,AH=49h,AH=83h
  4728. --------v-214A--BX00B6-----------------------
  4729. INT 21 - VIRUS???
  4730.     AH = 4Ah
  4731.     BX = 00B6h
  4732.     ES = CX
  4733. Return: ???
  4734. Note:    this call is intercepted by the Search&Destroy SDRes v27.03 bundled
  4735.       with Novell DOS 7, and is presumably some virus's installation check
  4736. SeeAlso: AH=0Eh/DL=ADh,AH=4Ah/BX=FFFFh,AH=D2h"VIRUS"
  4737. --------v-214A--BXFFFF-----------------------
  4738. INT 21 - VIRUS???
  4739.     AH = 4Ah
  4740.     BX = FFFFh
  4741.     CX = 0568h
  4742.     SI = 0129h
  4743.     DI = 0000h
  4744.     ES = BP
  4745. Return: ???
  4746. Note:    this call is intercepted by the Search&Destroy SDRes v27.03 bundled
  4747.       with Novell DOS 7, and is presumably some virus's installation check
  4748. SeeAlso: AH=0Eh/DL=ADh,AH=4Ah/BX=00B6h
  4749. --------D-214B-------------------------------
  4750. INT 21 - DOS 2+ - "EXEC" - LOAD AND/OR EXECUTE PROGRAM
  4751.     AH = 4Bh
  4752.     AL = type of load
  4753.         00h load and execute
  4754.         01h load but do not execute
  4755.         03h load overlay (see #0878)
  4756.         04h load and execute in background (European MS-DOS 4.0 only)
  4757.         "Exec & Go" (see also AH=80h)
  4758.     DS:DX -> ASCIZ program name (must include extension)
  4759.     ES:BX -> parameter block (see #0877,#0878,#0879)
  4760.     CX = mode (subfunction 04h only)
  4761.         0000h child placed in zombie mode after termination
  4762.         0001h child's return code discarded on termination
  4763. Return: CF clear if successful
  4764.         BX,DX destroyed
  4765.         if subfunction 01h, process ID set to new program's PSP; get with
  4766.         INT 21/AH=62h
  4767.     CF set on error
  4768.         AX = error code (01h,02h,05h,08h,0Ah,0Bh) (see #0960 at AH=59h)
  4769. Notes:    DOS 2.x destroys all registers, including SS:SP
  4770.     under ROM-based DOS, if no disk path characters (colons or slashes)
  4771.       are included in the program name, the name is searched for in the
  4772.       ROM module headers (see #0882) before searching on disk
  4773.     for functions 00h and 01h, the calling process must ensure that there
  4774.       is enough unallocated memory available; if necessary, by releasing
  4775.       memory with AH=49h or AH=4Ah
  4776.     for function 01h, the AX value to be passed to the child program is put
  4777.       on top of the child's stack
  4778.     for function 03h, DOS assumes that the overlay is being loaded into
  4779.       memory allocated by the caller
  4780.     function 01h was undocumented prior to the release of DOS 5.0
  4781.     some versions (such as DR DOS 6.0) check the parameters and parameter
  4782.       block and return an error if an invalid value (such as an offset of
  4783.       FFFFh) is found
  4784.     background programs under European MS-DOS 4.0 must use the new
  4785.       executable format
  4786.     this function ignores the filename extension, instead checking the
  4787.       first two bytes of the file to determine whether there is a valid
  4788.       .EXE header (see #0881); if not, the file is assumed to be in .COM
  4789.       format.  If present, the file may be in any of several formats which
  4790.       are extensions of the original .EXE format (see #0880)
  4791.     .COM-format executables begin running with the following register
  4792.       values:
  4793.         AL = 00h if first FCB has valid drive letter, FFh if not
  4794.         AH = 00h if second FCB has valid drive letter, FFh if not
  4795.         CS,DS,ES,SS = PSP segment
  4796.         SP = offset of last word available in first 64K segment
  4797.         (note: AX is always 0000h under DESQview)
  4798.     old-format executables begin running with the following register
  4799.       values:
  4800.         AL = 00h if first FCB has valid drive letter, FFh if not
  4801.         AH = 00h if second FCB has valid drive letter, FFh if not
  4802.         DS,ES = PSP segment
  4803.         SS:SP as defined in .EXE header
  4804.         (note: AX is always 0000h under DESQview)
  4805.     new executables begin running with the following register values
  4806.         AX = environment segment
  4807.         BX = offset of command tail in environment segment
  4808.         CX = size of automatic data segment (0000h = 64K)
  4809.         ES,BP = 0000h
  4810.         DS = automatic data segment
  4811.         SS:SP = initial stack
  4812.       the command tail corresponds to an old executable's PSP:0081h and
  4813.       following, except that the 0Dh is turned into a NUL (00h); new
  4814.       format executables have no PSP
  4815.     under the FlashTek X-32 DOS extender, only function 00h is supported
  4816.       and the pointers are passed in DS:EDX and ES:EBX
  4817.     DR DOS 6 always loads .EXE-format programs with no fixups and
  4818.       .COM-format programs starting with 9Ch 55h (PUSHF/PUSH BP) above the
  4819.       64K mark to avoid the EXEPACK bug, by extending the memory block
  4820.       containing the program's environment; this code is disabled if the
  4821.       name of the parent program as stored in the MCB is 'WIN'.
  4822. BUGS:    DOS 2.00 assumes that DS points at the current program's PSP
  4823.     Load Overlay (subfunction 03h) loads up to 512 bytes too many if the
  4824.       file contains additional data after the actual overlay
  4825. SeeAlso: AX=4B05h,AH=4Ch,AH=4Dh,AH=64h"OS/2",AH=8Ah,INT 2E,INT 60/DI=0604h
  4826.  
  4827. Format of EXEC parameter block for AL=00h,01h,04h:
  4828. Offset    Size    Description    (Table 0877)
  4829.  00h    WORD    segment of environment to copy for child process (copy caller's
  4830.           environment if 0000h)
  4831.  02h    DWORD    pointer to command tail to be copied into child's PSP
  4832.  06h    DWORD    pointer to first FCB to be copied into child's PSP
  4833.  0Ah    DWORD    pointer to second FCB to be copied into child's PSP
  4834.  0Eh    DWORD    (AL=01h) will hold subprogram's initial SS:SP on return
  4835.  12h    DWORD    (AL=01h) will hold entry point (CS:IP) on return
  4836. SeeAlso: #0878,#0879
  4837.  
  4838. Format of EXEC parameter block for AL=03h:
  4839. Offset    Size    Description    (Table 0878)
  4840.  00h    WORD    segment at which to load overlay
  4841.  02h    WORD    relocation factor to apply to overlay if in .EXE format
  4842. SeeAlso: #0877,#0879
  4843.  
  4844. Format of EXEC parameter block for FlashTek X-32:
  4845. Offset    Size    Description    (Table 0879)
  4846.  00h    PWORD    48-bit far pointer to environment string
  4847.  06h    PWORD    48-bit far pointer to command tail string
  4848. SeeAlso: #0877,#0878
  4849.  
  4850. (Table 0880)
  4851. Values for the executable types understood by various environments:
  4852.  MZ    old-style DOS executable (see #0881)
  4853.  NE    Windows or OS/2 1.x segmented ("new") executable (see #0883)
  4854.  LE    Windows virtual device driver (VxD) linear executable (see #0896)
  4855.  LX    variant of LE used in OS/2 2.x (see #0896)
  4856.  W3    Windows WIN386.EXE file; a collection of LE files
  4857.  PE    Win32 (Windows NT and Win32s) portable executable based on Unix COFF
  4858.  DL    HP 100LX/200LX system manager compliant executable (.EXM)
  4859.  MP    old PharLap .EXP (see #0906)
  4860.  P2    PharLap 286 .EXP (see #0907)
  4861.  P3    PharLap 386 .EXP (see #0907)
  4862.  
  4863. Format of .EXE file header:
  4864. Offset    Size    Description    (Table 0881)
  4865.  00h  2 BYTEs    .EXE signature, either "MZ" or "ZM" (5A4Dh or 4D5Ah)
  4866.           (see also #0880)
  4867.  02h    WORD    number of bytes in last 512-byte page of executable
  4868.  04h    WORD    total number of 512-byte pages in executable (includes any
  4869.         partial last page)
  4870.  06h    WORD    number of relocation entries
  4871.  08h    WORD    header size in paragraphs
  4872.  0Ah    WORD    minimum paragraphs of memory to allocation in addition to
  4873.         executable's size
  4874.  0Ch    WORD    maximum paragraphs to allocate in addition to executable's size
  4875.  0Eh    WORD    initial SS relative to start of executable
  4876.  10h    WORD    initial SP
  4877.  12h    WORD    checksum (one's complement of sum of all words in executable)
  4878.  14h    DWORD    initial CS:IP relative to start of executable
  4879.  18h    WORD    offset within header of relocation table
  4880.         40h or greater for new-format (NE,LE,LX,W3,PE,etc.) executable
  4881.  1Ah    WORD    overlay number (normally 0000h = main program)
  4882. ---new executable---
  4883.  1Ch  4 BYTEs    ???
  4884.  20h    WORD    behavior bits
  4885.  22h 26 BYTEs    reserved for additional behavior info
  4886.  3Ch    DWORD    offset of new executable (NE,LE,etc) header within disk file,
  4887.         or 00000000h if plain MZ executable
  4888. ---Borland TLINK---
  4889.  1Ch  2 BYTEs    ??? (apparently always 01h 00h)
  4890.  1Eh    BYTE    signature FBh
  4891.  1Fh    BYTE    TLINK version (major in high nybble, minor in low nybble)
  4892.  20h  2 BYTEs    ??? (v2.0 apparently always 72h 6Ah, v3.0+ seems always 6Ah 72h)
  4893. ---ARJ self-extracting archive---
  4894.  1Ch  4 BYTEs    signature "RJSX" (older versions, new signature is "aRJsfX" in
  4895.         the first 1000 bytes of the file)
  4896. ---LZEXE 0.90 compressed executable---
  4897.  1Ch  4 BYTEs    signature "LZ09"
  4898. ---LZEXE 0.91 compressed executable---
  4899.  1Ch  4 BYTEs    signature "LZ91"
  4900. ---PKLITE compressed executable---
  4901.  1Ch    BYTE    minor version number
  4902.  1Dh    BYTE    bits 0-3: major version
  4903.         bit 4: extra compression
  4904.         bit 5: huge (multi-segment) file
  4905.  1Eh  6 BYTEs    signature "PKLITE" (followed by copyright message)
  4906. ---LHarc 1.x self-extracting archive---
  4907.  1Ch  4 BYTEs    unused???
  4908.  20h  3 BYTEs    jump to start of extraction code
  4909.  23h  2 BYTEs    ???
  4910.  25h 12 BYTEs    signature "LHarc's SFX "
  4911. ---LHA 2.x self-extracting archive---
  4912.  1Ch  8 BYTEs    ???
  4913.  24h 10 BYTEs    signature "LHa's SFX " (v2.10) or "LHA's SFX " (v2.13)
  4914. ---TopSpeed C 3.0 CRUNCH compressed file---
  4915.  1Ch    DWORD    018A0001h
  4916.  20h    WORD    1565h
  4917. ---PKARCK 3.5 self-extracting archive---
  4918.  1Ch    DWORD    00020001h
  4919.  20h    WORD    0700h
  4920. ---BSA (Soviet archiver) self-extracting archive---
  4921.  1Ch    WORD    000Fh
  4922.  1Eh    BYTE    A7h
  4923. ---LARC self-extracting archive---
  4924.  1Ch  4 BYTEs    ???
  4925.  20h 11 BYTEs    "SFX by LARC "
  4926. ---LH self-extracting archive---
  4927.  1Ch  8 BYTEs    ???
  4928.  24h  8 BYTEs    "LH's SFX "
  4929. ---other linkers---
  4930.  1Ch    var    optional information
  4931. ---
  4932.   N   N DWORDs    relocation items
  4933. Notes:    if word at offset 02h is 4, it should be treated as 00h, since pre-1.10
  4934.       versions of the MS linker set it that way
  4935.     if both minimum and maximum allocation (offset 0Ah/0Ch) are zero, the
  4936.       program is loaded as high in memory as possible (DOS only checks
  4937.       the maximum allocation, however)
  4938.     the maximum allocation is set to FFFFh by default
  4939.     additional data may be contained in the file beyond the end of the
  4940.       load image described by the .EXE header; this data may be overlays,
  4941.       the actual executable for newer-format executables, or debugging
  4942.       information (see #0887,#0911)
  4943. SeeAlso: #0883
  4944.  
  4945. Format of ROM Module Header:
  4946. Offset    Size    Description    (Table 0882)
  4947.  00h  2 BYTEs    ROM signature 55h, AAh
  4948.  02h    BYTE    size of ROM in 512-byte blocks
  4949.  03h  3 BYTEs    POST initialization entry point (near JMP instruction)
  4950.  06h    ROM Program Name List [array]
  4951.     Offset    Size    Description
  4952.      00h    BYTE    length of ROM program's name (00h if end of name list)
  4953.      01h  N BYTEs    program name
  4954.      N+1  3 BYTEs    program entry point (near JMP instruction)
  4955.  
  4956. Format of new executable header:
  4957. Offset    Size    Description    (Table 0883)
  4958.  00h  2 BYTEs    "NE" (4Eh 45h) signature
  4959.  02h  2 BYTEs    linker version (major, then minor)
  4960.  04h    WORD    offset from start of this header to entry table (see #0890)
  4961.  06h    WORD    length of entry table in bytes
  4962.  08h    DWORD    file load CRC (0 in Borland's TPW)
  4963.  0Ch    BYTE    program flags (see #0884)
  4964.  0Dh    BYTE    application flags (see #0885)
  4965.  0Eh    WORD    auto data segment index
  4966.  10h    WORD    initial local heap size
  4967.  12h    WORD    initial stack size (added to data seg, 0000h if SS <> DS)
  4968.  14h    DWORD    program entry point (CS:IP), "CS" is index into segment table
  4969.  18h    DWORD    initial stack pointer (SS:SP), "SS" is segment index
  4970.         if SS=automatic data segment and SP=0000h, the stack pointer is
  4971.           set to the top of the automatic data segment, just below the
  4972.           local heap
  4973.  1Ch    WORD    segment count
  4974.  1Eh    WORD    module reference count
  4975.  20h    WORD    length of nonresident names table in bytes
  4976.  22h    WORD    offset from start of this header to segment table (see #0888)
  4977.  24h    WORD    offset from start of this header to resource table
  4978.  26h    WORD    offset from start of this header to resident names table
  4979.  28h    WORD    offset from start of this header to module reference table
  4980.  2Ah    WORD    offset from start of this header to imported names table
  4981.         (array of counted strings, terminated with a string of length
  4982.           00h)
  4983.  2Ch    DWORD    offset from start of file to nonresident names table
  4984.  30h    WORD    count of moveable entry point listed in entry table
  4985.  32h    WORD    file alignment size shift count
  4986.         0 is equivalent to 9 (default 512-byte pages)
  4987.  34h    WORD    number of resource table entries
  4988.  36h    BYTE    target operating system
  4989.         00h unknown
  4990.         01h OS/2
  4991.         02h Windows
  4992.         03h European MS-DOS 4.x
  4993.         04h Windows 386
  4994.         05h BOSS (Borland Operating System Services)
  4995.         81h PharLap 286|DOS-Extender, OS/2
  4996.         82h PharLap 286|DOS-Extender, Windows
  4997.  37h    BYTE    other EXE flags (see #0886)
  4998.  38h    WORD    offset to return thunks or start of gangload area
  4999.  3Ah    WORD    offset to segment reference thunks or length of gangload area
  5000.  3Ch    WORD    minimum code swap area size
  5001.  3Eh  2 BYTEs    expected Windows version (minor version first)
  5002. Note:    this header is documented in detail in the Windows 3.1 SDK Programmer's
  5003.       Reference, Vol 4.
  5004. SeeAlso: #0881
  5005.  
  5006. Bitfields for new executable program flags:
  5007. Bit(s)    Description    (Table 0884)
  5008.  0-1    DGROUP type
  5009.       0 = none
  5010.       1 = single shared
  5011.       2 = multiple (unshared)
  5012.       3 = (null)
  5013.  2    global initialization
  5014.  3    protected mode only
  5015.  4    8086 instructions
  5016.  5    80286 instructions
  5017.  6    80386 instructions
  5018.  7    80x87 instructions
  5019.  
  5020. Bitfields for new executable application flags:
  5021. Bit(s)    Description    (Table 0885)
  5022.  0-2    application type
  5023.     001 full screen (not aware of Windows/P.M. API)
  5024.     010 compatible with Windows/P.M. API
  5025.     011 uses Windows/P.M. API
  5026.  3    is a Family Application (OS/2)
  5027.  5    0=executable, 1=errors in image
  5028.  6    non-conforming program (valid stack is not maintained)
  5029.  7    DLL or driver rather than application
  5030.     (SS:SP info invalid, CS:IP points at FAR init routine called with
  5031.       AX=module handle which returns AX=0000h on failure, AX nonzero on
  5032.       successful initialization)
  5033.  
  5034. Bitfields for other new .EXE flags:
  5035. Bit(s)    Description    (Table 0886)
  5036.  0    supports long filenames
  5037.  1    2.X protected mode
  5038.  2    2.X proportional font
  5039.  3    gangload area
  5040.  
  5041. Format of Codeview trailer (at end of executable):
  5042. Offset    Size    Description    (Table 0887)
  5043.  00h    WORD    signature 4E42h ('NB')
  5044.  02h    WORD    Microsoft debug info version number
  5045.  04h    DWORD    Codeview header offset
  5046. SeeAlso: #0911
  5047.  
  5048. Format of new executable segment table record:
  5049. Offset    Size    Description    (Table 0888)
  5050.  00h    WORD    offset in file (shift left by alignment shift to get byte offs)
  5051.  02h    WORD    length of image in file (0000h = 64K)
  5052.  04h    WORD    segment attributes (see #0889)
  5053.  06h    WORD    number of bytes to allocate for segment (0000h = 64K)
  5054. Note:    the first segment table entry is entry number 1
  5055. SeeAlso: #0891
  5056.  
  5057. Bitfields for segment attributes:
  5058. Bit(s)    Description    (Table 0889)
  5059.  0    data segment rather than code segment
  5060.  1    unused???
  5061.  2    real mode
  5062.  3    iterated
  5063.  4    movable
  5064.  5    sharable
  5065.  6    preloaded rather than demand-loaded
  5066.  7    execute-only (code) or read-only (data)
  5067.  8    relocations (directly following code for this segment)
  5068.  9    debug info present
  5069.  10,11    80286 DPL bits
  5070.  12    discardable
  5071.  13-15    discard priority
  5072.  
  5073. Format of new executable entry table item (list):
  5074. Offset    Size    Description    (Table 0890)
  5075.  00h    BYTE    number of entry points (00h if end of entry table list)
  5076.  01h    BYTE    segment number (00h if end of entry table list)
  5077.  02h 3N BYTEs    entry records
  5078.         Offset    Size    Description
  5079.          00h    BYTE    flags
  5080.                 bit 0: exported
  5081.                 bit 1: single data
  5082.                 bits 2-7: unused???
  5083.          01h    WORD    offset within segment
  5084.  
  5085. Format of new executable relocation data (immediately follows segment image):
  5086. Offset    Size    Description    (Table 0891)
  5087.  00h    WORD    number of relocation items
  5088.  02h 8N BYTEs    relocation items
  5089.         Offset    Size    Description
  5090.          00h    BYTE    relocation type
  5091.                 00h LOBYTE
  5092.                 02h BASE
  5093.                 03h PTR
  5094.                 05h OFFS
  5095.                 0Bh PTR48
  5096.                 0Dh OFFS32
  5097.          01h    BYTE    flags
  5098.                 bit 2: additive
  5099.          02h    WORD    offset within segment
  5100.          04h    WORD    target address segment
  5101.          06h    WORD    target address offset
  5102. SeeAlso: #0888,#0892
  5103.  
  5104. Format of new executable resource data:
  5105. Offset    Size    Description    (Table 0892)
  5106.  00h    WORD    alignment shift count for resource data
  5107.  02h  N RECORDs resources
  5108.     Format of resource record:
  5109.     Offset    Size    Description
  5110.      00h    WORD    type ID
  5111.             0000h if end of resource records
  5112.             >= 8000h if integer type
  5113.             else offset from start of resource table to type string
  5114.      02h    WORD    number of resources of this type
  5115.      04h    DWORD    reserved for runtime use
  5116.      08h  N Resources (see #0893)
  5117. Note:    resource type and name strings are stored immediately following the
  5118.       resource table, and are not null-terminated
  5119. SeeAlso: #0893
  5120.  
  5121. Format of new executable resource entry:
  5122. Offset    Size    Description    (Table 0893)
  5123.  00h    WORD    offset in alignment units from start of file to contents of
  5124.         the resource data
  5125.  02h    WORD    length of resource image in bytes
  5126.  04h    WORD    flags
  5127.         bit 4: moveable
  5128.         bit 5: shareable
  5129.         bit 6: preloaded
  5130.  06h    WORD    resource ID
  5131.         >= 8000h if integer resource
  5132.         else offset from start of resource table to resource string
  5133.  08h    DWORD    reserved for runtime use
  5134. Notes:    resource type and name strings are stored immediately following the
  5135.       resource table, and are not null-terminated
  5136.     strings are counted strings, with a string of length 0 indicating the
  5137.       end of the resource table
  5138. SeeAlso: #0892,#0894
  5139.  
  5140. Format of new executable module reference table [one bundle of entries]:
  5141. Offset    Size    Description    (Table 0894)
  5142.  00h    BYTE    number of records in this bundle (00h if end of table)
  5143.  01h    BYTE    segment indicator
  5144.         00h unused
  5145.         FFh movable segment, segment number is in entry
  5146.         else segment number of fixed segment
  5147.  02h  N RECORDs
  5148.     Format of segment record
  5149.     Offset    Size    Description
  5150.      00h    BYTE    flags
  5151.             bit 0: entry is exported
  5152.             bit 1: entry uses global (shared) data
  5153.             bits 7-3: number of parameter words
  5154.     ---fixed segment---
  5155.      01h    WORD    offset
  5156.     ---moveable segment---
  5157.      01h  2 BYTEs    INT 3F instruction (CDh 3Fh)
  5158.      03h    BYTE    segment number
  5159.      05h    WORD    offset
  5160. Note:    table entries are numbered starting from 1
  5161. SeeAlso: #0895
  5162.  
  5163. Format of new executable resident/nonresident name table entry:
  5164. Offset    Size    Description    (Table 0895)
  5165.  00h    BYTE    length of string (00h if end of table)
  5166.  01h  N BYTEs    ASCII text of string
  5167.  N+1    WORD    ordinal number (index into entry table)
  5168. Notes:    the first string in the resident name table is the module name; the
  5169.       first entry in the nonresident name table is the module description
  5170.     the strings are case-sensitive; if the executable was linked with
  5171.       /IGNORECASE, all strings are in uppercase
  5172. SeeAlso: #0894
  5173.  
  5174. Format of Linear Executable (enhanced mode executable) header:
  5175. Offset    Size    Description    (Table 0896)
  5176.  00h  2 BYTEs    "LE" (4Ch 45h) signature (Windows)
  5177.         "LX" (4Ch 58h) signature (OS/2)
  5178.  02h    BYTE    byte order (00h = little-endian, nonzero = big-endian)
  5179.  03h    BYTE    word order (00h = little-endian, nonzero = big-endian)
  5180.  04h    DWORD    executable format level
  5181.  08h    WORD    CPU type (see also INT 15/AH=C9h)
  5182.         01h Intel 80286 or upwardly compatible
  5183.         02h Intel 80386 or upwardly compatible
  5184.         03h Intel 80486 or upwardly compatible
  5185.         04h Intel Pentium (80586) or upwardly compatible
  5186.         20h Intel i860 (N10) or compatible
  5187.         21h Intel "N11" or compatible
  5188.         40h MIPS Mark I (R2000, R3000) or compatible
  5189.         41h MIPS Mark II (R6000) or compatible
  5190.         42h MIPS Mark III (R4000) or compatible
  5191.  0Ah    WORD    target operating system
  5192.         01h OS/2
  5193.         02h Windows
  5194.         03h European DOS 4.0
  5195.         04h Windows 386
  5196.  0Ch    DWORD    module version
  5197.  10h    DWORD    module type (see #0897)
  5198.  14h    DWORD    number of memory pages
  5199.  18h    Initial CS:EIP
  5200.     DWORD    object number
  5201.     DWORD    offset
  5202.  20h    Initial SS:ESP
  5203.     DWORD    object number
  5204.     DWORD    offset
  5205.  28h    DWORD    memory page size
  5206.  2Ch    DWORD    (Windows LE) bytes on last page
  5207.         (OS/2 LX) page offset shift count
  5208.  30h    DWORD    fixup section size
  5209.  34h    DWORD    fixup section checksum
  5210.  38h    DWORD    loader section size
  5211.  3Ch    DWORD    loader section checksum
  5212.  40h    DWORD    offset of object table (see #0898)
  5213.  44h    DWORD    object table entries
  5214.  48h    DWORD    object page map table offset (see #0900)
  5215.  4Ch    DWORD    object iterate data map offset
  5216.  50h    DWORD    resource table offset
  5217.  54h    DWORD    resource table entries
  5218.  58h    DWORD    resident names table offset (see #0901)
  5219.  5Ch    DWORD    entry table offset (see #0902,#0903)
  5220.  60h    DWORD    module directives table offset
  5221.  64h    DWORD    Module Directives entries
  5222.  68h    DWORD    Fixup page table offset
  5223.  6Ch    DWORD    Fixup record table offset (see #0905)
  5224.  70h    DWORD    imported modules name table offset
  5225.  74h    DWORD    imported modules count
  5226.  78h    DWORD    imported procedures name table offset
  5227.  7Ch    DWORD    per-page checksum table offset
  5228.  80h    DWORD    data pages offset
  5229.  84h    DWORD    preload page count
  5230.  88h    DWORD    non-resident names table offset
  5231.  8Ch    DWORD    non-resident names table length
  5232.  90h    DWORD    non-resident names checksum
  5233.  94h    DWORD    automatic data object
  5234.  98h    DWORD    debug information offset
  5235.  9Ch    DWORD    debug information length
  5236.  A0h    DWORD    preload instance pages number
  5237.  A4h    DWORD    demand instance pages number
  5238.  A8h    DWORD    extra heap allocation
  5239.  ACh 12 BYTEs    reserved
  5240.  B8h    DWORD    offset of VERSIONINFO resource (MS-Windows VxD only)
  5241.  BCh    DWORD    pointer to ??? (dynamically-loadable VxDs only???)
  5242.  C0h    WORD    device ID (MS-Windows VxD only)
  5243.  C2h    WORD    DDK version (MS-Windows VxD only)
  5244. Note:    used by EMM386.EXE, QEMM, and Windows 3.0 Enhanced Mode drivers
  5245.  
  5246. Bitfields for Linear Executable module type:
  5247. Bit(s)    Description    (Table 0897)
  5248.  2    initialization (only for DLLs) 0 = global, 1 = per-process
  5249.  4    no internal fixups in executable image
  5250.  5    no external fixups in executable image
  5251.  8-10    API compatibility
  5252.     0 = unknown
  5253.     1 = incompatible with PM windowing \
  5254.     2 = compatible with PM windowing    > (only for
  5255.     3 = uses PM windowing API       /    programs)
  5256.  13    module not loadable (only for programs)
  5257.  15-17    module type
  5258.     000 program
  5259.     001 library (DLL)
  5260.     011 protected memory library module
  5261.     100 physical device driver
  5262.     110 virtual device driver
  5263.  30    per-process library termination
  5264.     (requires valid CS:EIP, can't be set for .EXE)
  5265.  
  5266. Format of object table entry:
  5267. Offset    Size    Description    (Table 0898)
  5268.  00h    DWORD    virtual size in bytes
  5269.  04h    DWORD    relocation base address
  5270.  08h    DWORD    object flags (see #0899)
  5271.  0Ch    DWORD    page map index
  5272.  10h    DWORD    page map entries (see #0900)
  5273.  14h  4 BYTEs    reserved??? (apparently always zeros)
  5274.  
  5275. Bitfields for object flags:
  5276. Bit(s)    Description    (Table 0899)
  5277.  0    readable
  5278.  1    writable
  5279.  2    executable
  5280.  3    resource
  5281.  4    discardable
  5282.  5    shared
  5283.  6    preloaded
  5284.  7    invalid
  5285.  8-9    type
  5286.     00 normal
  5287.     01 zero-filled
  5288.     10 resident
  5289.     11 resident and contiguous
  5290.  10    resident and long-lockable
  5291.  11    reserved
  5292.  12    16:16 alias required
  5293.  13    "BIG" (Huge: 32-bit)
  5294.  14    conforming
  5295.  15    "OBJECT_I/O_PRIVILEGE_LEVEL"
  5296.  16-31    reserved
  5297.  
  5298. Format of object page map table entry:
  5299. Offset    Size    Description    (Table 0900)
  5300.  00h    BYTE    ??? (usually 00h)
  5301.  01h    WORD    (big-endian) index to fixup table
  5302.         0000h if no relocation info
  5303.  03h    BYTE    type (00h hard copy in file, 03h some relocation needed)
  5304.  
  5305. Format of resident names table entry:
  5306. Offset    Size    Description    (Table 0901)
  5307.  00h    BYTE    length of name
  5308.  01h  N BYTEs    name
  5309.  N+1  3 BYTEs    ???
  5310.  
  5311. Format of LE linear executable entry table:
  5312. Offset    Size    Description    (Table 0902)
  5313.  00h    BYTE    number of entries in table
  5314.  01h 10 BYTEs per entry
  5315.         Offset    Size    Description
  5316.          00h    BYTE    bit flags
  5317.                 bit 0: non-empty bundle
  5318.                 bit 1: 32-bit entry
  5319.          01h    WORD    object number
  5320.          03h    BYTE    entry type flags
  5321.                 bit 0: exported
  5322.                 bit 1: uses single data rather than instance
  5323.                 bit 2: reserved
  5324.                 bits 3-7: number of stack parameters
  5325.          04h    DWORD    offset of entry point
  5326.          08h  2 BYTEs    ???
  5327. Note:    empty bundles (bit flags at 00h = 00h) are used to skip unused indices,
  5328.       and do not contain the remaining nine bytes
  5329.  
  5330. Format of LX linear executable entry table [array]:
  5331. Offset    Size    Description    (Table 0903)
  5332.  00h    BYTE    number of bundles following (00h = end of entry table)
  5333.  01h    BYTE    bundle type
  5334.         00h empty
  5335.         01h 16-bit entry
  5336.         02h 286 callgate entry
  5337.         03h 32-bit entry
  5338.         04h forwarder entry
  5339.         bit 7 set if additional parameter typing information is present
  5340. ---bundle type 00h---
  5341.  no additional fields
  5342. ---bundle type 01h---
  5343.  02h    WORD    object number
  5344.  04h    BYTE    entry flags
  5345.         bit 0: exported
  5346.         bits 7-3: number of stack parameters
  5347.  05h    WORD    offset of entry point in object (shifted by page size shift)
  5348. ---bundle type 02h---
  5349.  02h    WORD    object number
  5350.  04h    BYTE    entry flags
  5351.         bit 0: exported
  5352.         bits 7-3: number of stack parameters
  5353.  05h    WORD    offset of entry point in object
  5354.  07h    WORD    reserved for callgate selector (used by loader)
  5355. ---bundle type 03h---
  5356.  02h    WORD    object number
  5357.  04h    BYTE    entry flags
  5358.         bit 0: exported
  5359.         bits 7-3: number of stack parameters
  5360.  05h    DWORD    offset of entry point in object
  5361. ---bundle type 04h---
  5362.  02h    WORD    reserved
  5363.  04h    BYTE    forwarder flags
  5364.         bit 0: import by ordinal
  5365.         bits 7-1 reserved
  5366.  05h    WORD    module ordinal
  5367.         (forwarder's index into Import Module Name table)
  5368.  07h    DWORD    procedure name offset or import ordinal number
  5369. Note:    all fields after the first two bytes are repeated N times
  5370.  
  5371. Bitfields for linear executable fixup type:
  5372. Bit(s)    Description    (Table 0904)
  5373.  7    ordinal is BYTE rather than WORD
  5374.  6    16-rather than 8-object number/module ordinal
  5375.  5    addition with DWORD rather than WORD
  5376.  4    relocation info has size with new two bytes at end
  5377.  3    reserved (0)
  5378.  2    set if add to destination, clear to replace destination
  5379.  1-0    type
  5380.     00 internal fixup
  5381.     01 external fixup, imported by ordinal
  5382.     10 external fixup, imported by name
  5383.     11 internal fixup via entry table
  5384.  
  5385. Format of linear executable fixup record:
  5386. Offset    Size    Description    (Table 0905)
  5387.  00h    BYTE    type
  5388.         bits 7-4: modifier (0001 single, 0011 multiple)
  5389.         bits 3-0: type
  5390.             0000 byte offset
  5391.             0010 word segment
  5392.             0011 16-bit far pointer (DWORD)
  5393.             0101 16-bit offset
  5394.             0110 32-bit far pointer (PWORD)
  5395.             0111 32-bit offset
  5396.             1000 near call or jump, WORD/DWORD based on seg attrib
  5397.  01h    BYTE    linear executable fixup type (see #0904)
  5398. ---if single type---
  5399.  02h    WORD    offset within page
  5400.  04h    relocation information
  5401.     ---internal fixup---
  5402.     BYTE    object number
  5403.     ---external,ordinal---
  5404.     BYTE    one-based module number in Import Module table
  5405.     BYTE/WORD ordinal number
  5406.     WORD/DWORD value to add (only present if modifier bit 4 set)
  5407.     ---external,name---
  5408.     BYTE    one-based module number in Import Module table
  5409.     WORD    offset in Import Procedure names
  5410.     WORD/DWORD value to add (only present if modifier bit 4 set)
  5411. ---if multiple type---
  5412.  02h    BYTE    number of items
  5413.  03h    var    relocation info as for "single" type (see above)
  5414.       N WORDs    offsets of items to relocate
  5415.  
  5416. Format of old Phar Lap .EXP file header:
  5417. Offset    Size    Description    (Table 0906)
  5418.  00h  2 BYTEs    "MP" (4Dh 50h) signature
  5419.  02h    WORD    remainder of image size / page size (page size = 512h)
  5420.  04h    WORD    size of image in pages
  5421.  06h    WORD    number of relocation items
  5422.  08h    WORD    header size in paragraphs
  5423.  0Ah    WORD    minimum number of extra 4K pages to be allocated at the end
  5424.           of program, when it is loaded
  5425.  0Ch    WORD    maximum number of extra 4K pages to be allocated at the end
  5426.           of program, when it is loaded
  5427.  0Eh    DWORD    initial ESP
  5428.  12h    WORD    word checksum of file
  5429.  14h    DWORD    initial EIP
  5430.  18h    WORD    offset of first relocation item
  5431.  1Ah    WORD    overlay number
  5432.  1Ch    WORD    ??? (wants to be 1)
  5433. SeeAlso: #0907
  5434.  
  5435. Format of new Phar Lap .EXP file header:
  5436. Offset    Size    Description    (Table 0907)
  5437.  00h  2 BYTEs    signature ("P2" for 286 .EXP executable, "P3" for 386 .EXP)
  5438.  02h    WORD    level (01h flat-model file, 02h multisegmented file)
  5439.  04h    WORD    header size
  5440.  06h    DWORD    file size in bytes
  5441.  0Ah    WORD    checksum
  5442.  0Ch    DWORD    offset of run-time parameters within file (see #0909)
  5443.  10h    DWORD    size of run-time parameters in bytes
  5444.  14h    DWORD    offset of relocation table within file
  5445.  18h    DWORD    size of relocation table in bytes
  5446.  1Ch    DWORD    offset of segment information table within file (see #0908)
  5447.  20h    DWORD    size of segment information table in bytes
  5448.  24h    WORD    size of segment information table entry in bytes
  5449.  26h    DWORD    offset of load image within file
  5450.  2Ah    DWORD    size of load image on disk
  5451.  2Eh    DWORD    offset of symbol table within file or 00000000h
  5452.  32h    DWORD    size of symbol table in bytes
  5453.  36h    DWORD    offset of GDT within load image
  5454.  3Ah    DWORD    size of GDT in bytes
  5455.  3Eh    DWORD    offset of LDT within load image
  5456.  42h    DWORD    size of LDT in bytes
  5457.  46h    DWORD    offset of IDT within load image
  5458.  4Ah    DWORD    size of IDT in bytes
  5459.  4Eh    DWORD    offset of TSS within load image
  5460.  52h    DWORD    size of TSS in bytes
  5461.  56h    DWORD    minimum number of extra bytes to be allocated at end of program
  5462.         (level 1 executables only)
  5463.  5Ah    DWORD    maximum number of extra bytes to be allocated at end of program
  5464.         (level 1 executables only)
  5465.  5Eh    DWORD    base load offset (level 1 executables only)
  5466.  62h    DWORD    initial ESP
  5467.  66h    WORD    initial SS
  5468.  68h    DWORD    initial EIP
  5469.  6Ch    WORD    initial CS
  5470.  6Eh    WORD    initial LDT
  5471.  70h    WORD    initial TSS
  5472.  72h    WORD    flags
  5473.         bit 0: load image is packed
  5474.         bit 1: 32-bit checksum is present
  5475.         bits 4-2: type of relocation table
  5476.  74h    DWORD    memory requirements for load image
  5477.  78h    DWORD    32-bit checksum (optional)
  5478.  7Ch    DWORD    size of stack segment in bytes
  5479.  80h 256 BYTEs    reserved (0)
  5480. SeeAlso: #0906,#0910
  5481.  
  5482. Format of Phar Lap segment information table entry:
  5483. Offset    Size    Description    (Table 0908)
  5484.  00h    WORD    selector number
  5485.  02h    WORD    flags
  5486.  04h    DWORD    base offset of selector
  5487.  08h    DWORD    minimum number of extra bytes to be allocated to the segment
  5488.  
  5489. Format of 386|DOS-Extender run-time parameters:
  5490. Offset    Size    Description    (Table 0909)
  5491.  00h  2 BYTEs    signature "DX" (44h 58h)
  5492.  02h    WORD    minimum number of real-mode params to leave free at run time
  5493.  04h    WORD    maximum number of real-mode params to leave free at run time
  5494.  06h    WORD    minimum interrupt buffer size in KB
  5495.  08h    WORD    maximum interrupt buffer size in KB
  5496.  0Ah    WORD    number of interrupt stacks
  5497.  0Ch    WORD    size in KB of each interrupt stack
  5498.  0Eh    DWORD    offset of byte past end of real-mode code and data
  5499.  12h    WORD    size in KB of call buffers
  5500.  14h    WORD    flags
  5501.         bit 0: file is virtual memory manager
  5502.         bit 1: file is a debugger
  5503.  16h    WORD    unprivileged flag (if nonzero, executes at ring 1, 2, or 3)
  5504.  18h 104 BYTEs    reserved (0)
  5505.  
  5506. Format of Phar Lap repeat block header:
  5507. Offset    Size    Description    (Table 0910)
  5508.  00h    WORD    byte count
  5509.  02h    BYTE    repeat string length
  5510.  
  5511. Format of Borland debugging information header (following load image):
  5512. Offset    Size    Description    (Table 0911)
  5513.  00h    WORD    signature 52FBh
  5514.  02h    WORD    version ID
  5515.  04h    DWORD    size of name pool in bytes
  5516.  08h    WORD    number of names in name pool
  5517.  0Ah    WORD    number of type entries
  5518.  0Ch    WORD    number of structure members
  5519.  0Eh    WORD    number of symbols
  5520.  10h    WORD    number of global symbols
  5521.  12h    WORD    number of modules
  5522.  14h    WORD    number of locals (optional)
  5523.  16h    WORD    number of scopes in table
  5524.  18h    WORD    number of line-number entries
  5525.  1Ah    WORD    number of include files
  5526.  1Ch    WORD    number of segment records
  5527.  1Eh    WORD    number of segment/file correlations
  5528.  20h    DWORD    size of load image after removing uninitialized data and debug
  5529.           information
  5530.  24h    DWORD    debugger hook; pointer into debugged program whose meaning
  5531.           depends on program flags
  5532.  28h    BYTE    program flags
  5533.         bit 0: case-sensitive link
  5534.         bit 1: pascal overlay program
  5535.  29h    WORD    no longer used
  5536.  2Bh    WORD    size of data pool in bytes
  5537.  2Dh    BYTE    padding
  5538.  2Eh    WORD    size of following header extension (currently 00h, 10h, or 20h)
  5539.  30h    WORD    number of classes
  5540.  32h    WORD    number of parents
  5541.  34h    WORD    number of global classes (currently unused)
  5542.  36h    WORD    number of overloads (currently unused)
  5543.  38h    WORD    number of scope classes
  5544.  3Ah    WORD    number of module classes
  5545.  3Ch    WORD    number of coverage offsets
  5546.  3Eh    DWORD    offset relative to symbol base of name pool
  5547.  42h    WORD    number of browser information records
  5548.  44h    WORD    number of optimized symbol records
  5549.  46h    WORD    debugging flags
  5550.  48h  8 BYTEs    padding
  5551. Note:    additional information on the Borland debugging info may be found in
  5552.       Borland's Open Architecture Handbook
  5553. SeeAlso: #0887
  5554. --------U-214B-------------------------------
  5555. INT 21 - ELRES v1.0 only - INSTALLATION CHECK
  5556.     AH = 4Bh
  5557.     DS:DX = 0000h:0000h
  5558. Return: ES:BX -> ELRES history structure (see #0680 at AH=2Bh/CX=454Ch)
  5559.     DX = DABEh (signature, DAve BEnnett)
  5560. Program: ELRES is an MS-DOS return code (errorlevel) recorder by David H.
  5561.       Bennett
  5562. SeeAlso: AH=2Bh/CX=454Ch
  5563. --------v-214B04-----------------------------
  5564. INT 21 - VIRUS - "MG", "699"/"Thirteen Minutes" - INSTALLATION CHECK
  5565.     AX = 4B04h
  5566. Return: CF clear if "MG" resident
  5567.     AX = 044Bh if "699"/"Thirteen Minutes" resident
  5568. SeeAlso: AX=4243h,AH=4Ah/BX=FFFFh,AX=4B21h
  5569. --------D-214B05-----------------------------
  5570. INT 21 - DOS 5+ - SET EXECUTION STATE
  5571.     AX = 4B05h
  5572.     DS:DX -> execution state structure (see #0912)
  5573. Return: CF clear if successful
  5574.         AX = 0000h
  5575.     CF set on error
  5576.         AX = error code (see #0960 at AH=59h)
  5577. Note:    used by programs which intercept AX=4B00h to prepare new programs for
  5578.       execution (including setting the DOS version number).     No DOS, BIOS
  5579.       or other software interrupt may be called after return from this call
  5580.       before commencement of the child process.  If DOS is running in the
  5581.       HMA, A20 is turned off on return from this call.
  5582. SeeAlso: AH=4Bh
  5583.  
  5584. Format of execution state structure:
  5585. Offset    Size    Description    (Table 0912)
  5586.  00h    WORD    reserved (00h)
  5587.  02h    WORD    type flags
  5588.         bit 0: program is an .EXE
  5589.         bit 1: program is an overlay
  5590.  04h    DWORD    pointer to ASCIZ name of program file
  5591.  08h    WORD    PSP segment of new program
  5592.  0Ah    DWORD    starting CS:IP of new program
  5593.  0Eh    DWORD    program size including PSP
  5594. --------v-214B20-----------------------------
  5595. INT 21 - VIRUS - "Holocaust"/"Telefonica" - ???
  5596.     AX = 4B20h
  5597. SeeAlso: AX=4B04h,AX=4B21h
  5598. --------v-214B21-----------------------------
  5599. INT 21 C - VIRUS - "Holocaust"/"Telefonica" - ???
  5600.     AX = 4B21h
  5601. Note:    called at completion of virus installation
  5602. SeeAlso: AX=4B04h,AX=4B20h,AX=4B25h
  5603. --------v-214B25-----------------------------
  5604. INT 21 - VIRUS - "1063"/"Mono" - INSTALLATION CHECK
  5605.     AX = 4B25h
  5606. Return: DI = 1234h if resident
  5607. SeeAlso: AX=4B21h,AX=4B40h
  5608. --------v-214B40-----------------------------
  5609. INT 21 - VIRUS - "Plastique"/"AntiCad" - INSTALLATION CHECK
  5610.     AX = 4B40h
  5611. Return: AX = 5678h if resident
  5612. SeeAlso: AX=4B25h,AX=4B41h,AX=4B4Ah
  5613. --------v-214B41-----------------------------
  5614. INT 21 - VIRUS - "Plastique"/"AntiCad" - ???
  5615.     AX = 4B41h
  5616.     ???
  5617. Return: ???
  5618. SeeAlso: AX=4B40h
  5619. --------v-214B4A-----------------------------
  5620. INT 21 - VIRUS - "Jabberwocky" - INSTALLATION CHECK
  5621.     AX = 4B4Ah
  5622. Return: AL = 57h if resident
  5623. SeeAlso: AX=4B40h,AX=4B4Bh
  5624. --------v-214B4B-----------------------------
  5625. INT 21 - VIRUS - "Horse-2" - INSTALLATION CHECK
  5626.     AX = 4B4Bh
  5627. Return: CF clear if resident
  5628. SeeAlso: AX=4B4Ah,AX=4B4Dh
  5629. --------v-214B4D-----------------------------
  5630. INT 21 - VIRUS - "Murphy-2", "Patricia"/"Smack" - INSTALLATION CHECK
  5631.     AX = 4B4Dh
  5632. Return: CF clear if resident
  5633. SeeAlso: AX=4B4Ah,AX=4B50h
  5634. --------v-214B50-----------------------------
  5635. INT 21 - VIRUS - "Plastique-2576"/"AntiCad-2576" - INSTALLATION CHECK
  5636.     AX = 4B50h
  5637. Return: AX = 1234h if resident
  5638. SeeAlso: AX=4B4Dh,AX=4B53h,AX=4B60h
  5639. --------v-214B53-----------------------------
  5640. INT 21 - VIRUS - "Horse" - INSTALLATION CHECK
  5641.     AX = 4B53h
  5642. Return: CF clear if resident
  5643. SeeAlso: AX=4B50h,AX=4B53h/BX=2121h,AX=4B55h
  5644. --------v-214B53BX2121-----------------------
  5645. INT 21 - VIRUS - "One Half" - INSTALLATION CHECK
  5646.     AX = 4B53h
  5647.     BX = 2121h
  5648.     CX = 1212h
  5649.     DX = 0236h
  5650. Return: AX = 454Bh if installed
  5651. SeeAlso: AX=4B50h,AX=4B53h,AX=4B55h
  5652. --------v-214B55-----------------------------
  5653. INT 21 - VIRUS - "Sparse" - INSTALLATION CHECK
  5654.     AX = 4B55h
  5655. Return: AX = 1231h if resident
  5656. SeeAlso: AX=4B53h,AX=4B59h
  5657. --------v-214B59-----------------------------
  5658. INT 21 - VIRUS - "Murphy-1", "Murphy-4" - INSTALLATION CHECK
  5659.     AX = 4B59h
  5660. Return: CF clear if resident
  5661. SeeAlso: AX=4B50h,AX=4B5Eh
  5662. --------v-214B5E-----------------------------
  5663. INT 21 - VIRUS - "Brothers" - INSTALLATION CHECK
  5664.     AX = 4B5Eh
  5665. Return: CF clear if resident
  5666. SeeAlso: AX=4B59h,AX=4B87h
  5667. --------v-214B60-----------------------------
  5668. INT 21 - VIRUS - "Plastique-2576"/"AntiCad-2576" - ???
  5669.     AX = 4B60h
  5670.     ???
  5671. Return: ???
  5672. SeeAlso: AX=4B50h
  5673. --------v-214B87-----------------------------
  5674. INT 21 - VIRUS - "Shirley" - INSTALLATION CHECK
  5675.     AX = 4B87h
  5676. Return: AX = 6663h if resident
  5677. SeeAlso: AX=4B5Eh,AX=4B95h
  5678. --------v-214B95-----------------------------
  5679. INT 21 - VIRUS - "Zherkov-1882" - INSTALLATION CHECK
  5680.     AX = 4B95h
  5681. Return: AX = 1973h if resident
  5682. SeeAlso: AX=4B87h,AX=4BA7h
  5683. --------v-214BA7-----------------------------
  5684. INT 21 - VIRUS - "1876"/"Dash-em" - INSTALLATION CHECK
  5685.     AX = 4BA7h
  5686. Return: AX = B459h if resident
  5687. SeeAlso: AX=4B95h,AX=4BAAh
  5688. --------v-214BAA-----------------------------
  5689. INT 21 - VIRUS - "Nomenklatura" - INSTALLATION CHECK
  5690.     AX = 4BAAh
  5691. Return: CF clear if resident
  5692. SeeAlso: AX=4BA7h,AX=4BAFh
  5693. --------v-214BAF-----------------------------
  5694. INT 21 - VIRUS - "948"/"Screenplus1", "Magnitogorsk" - INSTALLATION CHECK
  5695.     AX = 4BAFh
  5696. Return: AL = AFh if "Magnitogorsk" resident
  5697.     AL = FAh if "948"/"Screenplus1" resident
  5698. SeeAlso: AX=4BAAh,AX=4BDDh
  5699. --------v-214BDD-----------------------------
  5700. INT 21 - VIRUS - "Lozinsky"/"Zherkov" - INSTALLATION CHECK
  5701.     AX = 4BDDh
  5702. Return: AX = 1234h
  5703. SeeAlso: AX=4BAFh,AX=4BFEh
  5704. --------v-214BEE-----------------------------
  5705. INT 21 - F-DRIVER.SYS v1.14+ - GRAB INT 21
  5706.     AX = 4BEEh
  5707. Return: AX = status
  5708.         1234h grab was successful
  5709.         2345h failed (INT 21 grabbed previously)
  5710. Program: F-DRIVER.SYS is part of the shareware F-PROT virus/trojan protection
  5711.       package by Fridrik Skulason
  5712. Note:    when called the first time, this function moves the INT 21 monitoring
  5713.       code from its original location in the INT 21 chain to be the first
  5714.       thing called by INT 21.  This is the mechanism used by F-NET.
  5715. SeeAlso: INT 2F/AX=4653h
  5716. --------k-214BF0-----------------------------
  5717. INT 21 - DIET v1.10+ (Overlay Mode) - INSTALLATION CHECK
  5718.     AX = 4BF0h
  5719. Return: CF clear if installed
  5720.         AX = 899Dh
  5721. Program: DIET is an executable-compression program by Teddy Matsumoto
  5722. SeeAlso: AX=37D0h,AX=4BF1h
  5723. --------k-214BF1-----------------------------
  5724. INT 21 - DIET v1.10+ (Overlay Mode) - EXPAND PROGRAM???
  5725.     AX = 4BF1h
  5726. Return: ???
  5727. SeeAlso: AX=37D0h,AX=4BF0h
  5728. --------v-214BF1-----------------------------
  5729. INT 21 - VIRUS - "Jerusalem 2" - INSTALLATION CHECK
  5730.     AX = 4BF1h
  5731. Return: AX = 1FB4h if resident
  5732. SeeAlso: AX=3Fh/BX=FEB0h"VIRUS",AX=4BDDh"VIRUS",AX=4BFEh"VIRUS"
  5733. --------v-214BFE-----------------------------
  5734. INT 21 - VIRUS - "Hitchcock", "Dark Avenger-1028", "1193" - INSTALLATION CHECK
  5735.     AX = 4BFEh
  5736. Return: AX = 1234h if "Hitchcock" or "Storm" resident
  5737.     AX = ABCDh if "1193"/"Copyright" resident
  5738.     DI = 55BBh if "Dark Avenger-1028" resident
  5739. SeeAlso: AX=4BDDh,AX=4BF1h"VIRUS",AX=4BFFh"Justice"
  5740. --------v-214BFF-----------------------------
  5741. INT 21 - VIRUS - "USSR-707", "Justice", "Europe 92" - INSTALLATION CHECK
  5742.     AX = 4BFFh
  5743. Return: BL = FFh if "USSR-707" resident
  5744.     DI = 55AAh if "Justice" resident
  5745.     AX = 1234h if "Hitchcock.1238" resident
  5746.     CF clear if "Europe 92" resident
  5747. SeeAlso: AX=4BFEh,AX=4BFFh"Cascade",AX=5252h
  5748. --------v-214BFFSI0000-----------------------
  5749. INT 21 - VIRUS - "Cascade" - INSTALLATION CHECK
  5750.     AX = 4BFFh
  5751.     SI = 0000h
  5752.     DI = 0000h
  5753. Return: DI = 55AAh if installed
  5754. SeeAlso: AX=4BFFh"Justice",AX=5252h
  5755. --------D-214C-------------------------------
  5756. INT 21 - DOS 2+ - "EXIT" - TERMINATE WITH RETURN CODE
  5757.     AH = 4Ch
  5758.     AL = return code
  5759. Return: never returns
  5760. Notes:    unless the process is its own parent (see #0677 at AH=26h, offset 16h
  5761.       in PSP), all open files are closed and all memory belonging to the
  5762.       process is freed
  5763.     all network file locks should be removed before calling this function
  5764. SeeAlso: AH=00h,AH=26h,AH=4Bh,AH=4Dh,INT 15/AH=12h/BH=02h,INT 20,INT 22
  5765. SeeAlso: INT 60/DI=0601h
  5766. --------m-214C57-----------------------------
  5767. INT 21 - Headroom - ???
  5768.     AX = 4C57h
  5769.     DS:DX -> target address
  5770. Note:    jumps to target address instead of terminating program
  5771. SeeAlso: AX=5758h
  5772. --------D-214D-------------------------------
  5773. INT 21 - DOS 2+ - GET RETURN CODE (ERRORLEVEL)
  5774.     AH = 4Dh
  5775. Return: AH = termination type
  5776.         00h normal (INT 20,INT 21/AH=00h, or INT 21/AH=4Ch)
  5777.         01h control-C abort
  5778.         02h critical error abort
  5779.         03h terminate and stay resident (INT 21/AH=31h or INT 27)
  5780.     AL = return code
  5781. Notes:    the word in which DOS stores the return code is cleared after being
  5782.       read by this function, so the return code can only be retrieved once
  5783.     COMMAND.COM stores the return code of the last external command it
  5784.       executed as ERRORLEVEL
  5785.     this call should not be used if the child was started with AX=4B04h;
  5786.       use AH=8Ah instead
  5787.     the following sequence will close a Virtual DOS Machine under OS/2 2.0:
  5788.       MOV    AH,4Dh
  5789.       INT    21h
  5790.       HLT
  5791.       DB    02h,0FDh
  5792.       This sequence is the only way to close a specific VDM which was
  5793.       booted from floppy or a disk image.
  5794. SeeAlso: AH=4Bh,AH=4Ch,AH=8Ah
  5795. --------D-214E-------------------------------
  5796. INT 21 - DOS 2+ - "FINDFIRST" - FIND FIRST MATCHING FILE
  5797.     AH = 4Eh
  5798.     AL = special flag for use by APPEND (see note below)
  5799.     CX = file attribute mask (see #0717 at AX=4301h) (bits 0 and 5 ignored)
  5800.         0088h (Novell DOS 7) find first deleted file
  5801.     DS:DX -> ASCIZ file specification (may include path and wildcards)
  5802. Return: CF clear if successful
  5803.         [DTA] = FindFirst data block (see #0913)
  5804.     CF set on error
  5805.         AX = error code (02h,03h,12h) (see #0960 at AH=59h)
  5806. Notes:    for search attributes other than 08h, all files with at MOST the
  5807.       specified combination of hidden, system, and directory attributes
  5808.       will be returned.  Under DOS 2.x, searching for attribute 08h
  5809.       (volume label) will also return normal files, while under DOS 3.0+
  5810.       only the volume label (if any) will be returned.
  5811.     this call also returns successfully if given the name of a character
  5812.       device without wildcards.  DOS 2.x returns attribute 00h, size 0,
  5813.       and the current date and time.  DOS 3.0+ returns attribute 40h and
  5814.       the current date and time.
  5815.     immediately after an INT 2F/AX=B711h (APPEND return found name), the
  5816.       name at DS:DX will be overwritten; if AL=00h on entry, the actual
  5817.       found pathname will be stored, otherwise, the actual found path
  5818.       will be prepended to the original filespec without a path.
  5819.     under LANtastic, this call may be used to obtain a list of a server's
  5820.       shared resources by searching for "\\SERVER\*.*"; a list of printer
  5821.       resources may be obtained by searching for "\\SERVER\@*.*"
  5822.     under the FlashTek X-32 DOS extender, the filespec pointer is in DS:EDX
  5823. BUGS:    under DOS 3.x and 4.x, the second and subsequent calls to this function
  5824.       with a character device name (no wildcards) and search attributes
  5825.       which include the volume-label bit (08h) will fail unless there is
  5826.       an intervening DOS call which implicitly or explicity performs a
  5827.       directory search without the volume-label bit.  Such implicit
  5828.       searches are performed by CREATE (AH=3Ch), OPEN (AH=3Dh), UNLINK
  5829.       (AH=41h), and RENAME (AH=56h)
  5830.     DR DOS 3.41 and 5.0 return the Directory attribute for the volume label
  5831. SeeAlso: AH=11h,AH=4Fh,AX=4301h,AX=714Eh,AX=71A1h,AX=F257h/SF=02h
  5832. SeeAlso: INT 2F/AX=111Bh,INT 2F/AX=B711h
  5833.  
  5834. Format of FindFirst data block:
  5835. Offset    Size    Description    (Table 0913)
  5836. ---PC-DOS 3.10, PC-DOS 4.01, MS-DOS 3.2/3.3/5.0---
  5837.  00h    BYTE    drive letter (bits 0-6), remote if bit 7 set
  5838.  01h 11 BYTEs    search template
  5839.  0Ch    BYTE    search attributes
  5840. ---DOS 2.x (and some DOS 3.x???)---
  5841.  00h    BYTE    search attributes
  5842.  01h    BYTE    drive letter
  5843.  02h 11 BYTEs    search template
  5844. ---WILDUNIX.COM---
  5845.  00h 12 BYTEs    15-character wildcard search pattern and drive letter (packed)
  5846.  0Ch    BYTE    search attributes
  5847. ---DOS 2.x and most 3.x---
  5848.  0Dh    WORD    entry count within directory
  5849.  0Fh    DWORD    pointer to DTA???
  5850.  13h    WORD    cluster number of start of parent directory
  5851. ---PC-DOS 4.01, MS-DOS 3.2/3.3/5.0---
  5852.  0Dh    WORD    entry count within directory
  5853.  0Fh    WORD    cluster number of start of parent directory
  5854.  11h  4 BYTEs    reserved
  5855. ---all versions, documented fields---
  5856.  15h    BYTE    attribute of file found
  5857.  16h    WORD    file time (see #0951 at AX=5700h)
  5858.  18h    WORD    file date (see #0952 at AX=5700h)
  5859.  1Ah    DWORD    file size
  5860.  1Eh 13 BYTEs    ASCIZ filename+extension
  5861. --------f-214E-------------------------------
  5862. INT 21 - WILDUNIX.COM internal - INSTALLATION CHECK
  5863.     AH = 4Eh
  5864.     DS:DX = 0000h:0000h
  5865. Return: AH = 99h if installed
  5866. Program: WILDUNIX.COM is a resident Unix-style wildcard expander by Steve
  5867.       Hosgood and Terry Barnaby
  5868. --------D-214F-------------------------------
  5869. INT 21 - DOS 2+ - "FINDNEXT" - FIND NEXT MATCHING FILE
  5870.     AH = 4Fh
  5871.     [DTA] = data block from previous FindFirst or FindNext call
  5872. Return: CF clear if successful
  5873.     CF set on error
  5874.         AX = error code (12h) (see #0960 at AH=59h)
  5875. Note:    under Novell DOS 7, if the FindFirst call (AH=4Eh) had CX=0088h, then
  5876.       the next matching deleted file will be returned
  5877. BUG:    DR DOS 3.41 and 5.0 return the Directory attribute for the volume label
  5878. SeeAlso: AH=12h,AH=4Eh,AX=714Fh,AX=71A1h
  5879. --------D-2150-------------------------------
  5880. INT 21 - DOS 2+ internal - SET CURRENT PROCESS ID (SET PSP ADDRESS)
  5881.     AH = 50h
  5882.     BX = segment of PSP for new process
  5883. Notes:    DOS uses the current PSP address to determine which processes own files
  5884.       and memory; it corresponds to process identifiers used by other OSs
  5885.     under DOS 2.x, this function cannot be invoked inside an INT 28h
  5886.       handler without setting the Critical Error flag
  5887.     under MS-DOS 3.0+ and DR DOS 3.41+, this function does not use any of
  5888.       the DOS-internal stacks and may thus be called at any time, even
  5889.       during another INT 21h call
  5890.     some Microsoft applications such as Quick C 2.51 use segments of 0000h
  5891.       and FFFFh and direct access to the SDA (see #0967 at AX=5D06h) to
  5892.       test whether they are running under MS-DOS rather than a compatible
  5893.       OS; although one should only call this function with valid PSP
  5894.       addresses, any program hooking it should be prepared to handle
  5895.       invalid addresses
  5896.     this function is supported by the OS/2 compatibility box
  5897.     this call was undocumented prior to the release of DOS 5.0
  5898. SeeAlso: AH=26h,AH=51h,AH=62h
  5899. --------v-2150FD-----------------------------
  5900. INT 21 - VIRUS - "Predator 2" - INSTALLATION CHECK
  5901.     AX = 50FDh
  5902. Return: AX = FD50h if resident
  5903. SeeAlso: AX=4BFFh"VIRUS",AX=5454h"VIRUS"
  5904. --------D-2151-------------------------------
  5905. INT 21 - DOS 2+ internal - GET CURRENT PROCESS ID (GET PSP ADDRESS)
  5906.     AH = 51h
  5907. Return: BX = segment of PSP for current process
  5908. Notes:    DOS uses the current PSP address to determine which processes own files
  5909.       and memory; it corresponds to process identifiers used by other OSs
  5910.     under DOS 2.x, this function cannot be invoked inside an INT 28h
  5911.       handler without setting the Critical Error flag
  5912.     under DOS 3.0+, this function does not use any of the DOS-internal
  5913.       stacks and may thus be called at any time, even during another
  5914.       INT 21h call
  5915.     supported by OS/2 compatibility box
  5916.     identical to the documented AH=62h
  5917.     this call was undocumented prior to the release of DOS 5.0
  5918. SeeAlso: AH=26h,AH=50h,AH=62h
  5919. --------D-2152-------------------------------
  5920. INT 21 U - DOS 2+ internal - "SYSVARS" - GET LIST OF LISTS
  5921.     AH = 52h
  5922. Return: ES:BX -> DOS list of lists (see #0914)
  5923. Notes:    partially supported by OS/2 v1.1 compatibility box (however, most
  5924.       pointers are FFFFh:FFFFh, LASTDRIVE is FFh, and the NUL header "next"
  5925.       pointer is FFFFh:FFFFh).
  5926.     partially supported by the Windows NT DOS box; contains only a
  5927.       rudimentary Current Directory Structure (see #0932)
  5928.     on return, ES points at the DOS data segment (see also INT 2F/AX=1203h)
  5929.     Quarterdeck's suggested check for the use of its DOSDATA.SYS or
  5930.       DOS-UP.SYS is to test whether the list-of-lists segment is greater
  5931.       than the segment of the first memory block; a better check for
  5932.       DOS-UP.SYS is INT 21/AX=2B01h/CX=444Dh
  5933. SeeAlso: INT 2F/AX=1203h
  5934.  
  5935. Format of List of Lists:
  5936. Offset    Size    Description    (Table 0914)
  5937.  -24    WORD    (DOS 3.1+) contents of CX from INT 21/AX=5E01h
  5938.  -22    WORD    (DOS ???+) LRU counter for FCB caching
  5939.  -20    WORD    (DOS ???+) LRU counter for FCB opens
  5940.  -18    DWORD    (DOS ???+) address of OEM function handler (see INT 21/AH=F8h)
  5941.             FFFFh:FFFFh if not installed or not available
  5942.  -14    WORD    (DOS ???+) offset in DOS CS of code to return from INT 21 call
  5943.  -12    WORD    (DOS 3.1+) sharing retry count (see AX=440Bh)
  5944.  -10    WORD    (DOS 3.1+) sharing retry delay (see AX=440Bh)
  5945.  -8    DWORD    (DOS 3.0+) pointer to current disk buffer
  5946.  -4    WORD    (DOS 3.0+) pointer in DOS data segment of unread CON input
  5947.         when CON is read via a handle, DOS reads an entire line,
  5948.           and returns the requested portion, buffering the rest
  5949.           for the next read.  0000h indicates no unread input
  5950.  -2    WORD    segment of first memory control block (see #0915)
  5951.  00h    DWORD    pointer to first Drive Parameter Block (see #0694 at AH=32h)
  5952.  04h    DWORD    -> first System File Table (see #0926,#0927,#0928,#0929)
  5953.  08h    DWORD    pointer to active CLOCK$ device's header (most recently loaded
  5954.           driver with CLOCK bit set)
  5955.  0Ch    DWORD    pointer to active CON device's header (most recently loaded
  5956.           driver with STDIN bit set)
  5957. ---DOS 2.x---
  5958.  10h    BYTE    number of logical drives in system
  5959.  11h    WORD    maximum bytes/block of any block device
  5960.  13h    DWORD    pointer to first disk buffer (see #0936,#0937)
  5961.  17h 18 BYTEs    actual NUL device driver header (not a pointer!)
  5962.         NUL is always the first device on DOS's linked list of device
  5963.           drivers. (see #0933)
  5964. ---DOS 3.0---
  5965.  10h    BYTE    number of block devices
  5966.  11h    WORD    maximum bytes/block of any block device
  5967.  13h    DWORD    pointer to first disk buffer (see #0937,#0939)
  5968.  17h    DWORD    pointer to array of current directory structures (see #0930)
  5969.  1Bh    BYTE    value of LASTDRIVE command in CONFIG.SYS (default 5)
  5970.  1Ch    DWORD    pointer to STRING= workspace area
  5971.  20h    WORD    size of STRING area (the x in STRING=x from CONFIG.SYS)
  5972.  22h    DWORD    pointer to FCB table
  5973.  26h    WORD    the y in FCBS=x,y from CONFIG.SYS
  5974.  28h 18 BYTEs    actual NUL device driver header (not a pointer!)
  5975.         NUL is always the first device on DOS's linked list of device
  5976.           drivers. (see #0933)
  5977. ---DOS 3.1-3.3---
  5978.  10h    WORD    maximum bytes per sector of any block device
  5979.  12h    DWORD    pointer to first disk buffer in buffer chain (see #0937)
  5980.  16h    DWORD    pointer to array of current directory structures (see #0930)
  5981.  1Ah    DWORD    pointer to system FCB tables (see #0927,#0928,#0929)
  5982.  1Eh    WORD    number of protected FCBs (the y in the CONFIG.SYS FCBS=x,y)
  5983.  20h    BYTE    number of block devices installed
  5984.  21h    BYTE    number of available drive letters (largest of 5, installed
  5985.           block devices, and CONFIG.SYS LASTDRIVE=).  Also size of
  5986.           current directory structure array.
  5987.  22h 18 BYTEs    actual NUL device driver header (not a pointer!)
  5988.         NUL is always the first device on DOS's linked list of device
  5989.           drivers. (see #0933)
  5990.  34h    BYTE    number of JOIN'ed drives
  5991. ---DOS 4.x---
  5992.  10h    WORD    maximum bytes per sector of any block device
  5993.  12h    DWORD    pointer to disk buffer info record (see #0939,#0940)
  5994.         Note: although the initialization code in IO.SYS uses this
  5995.           pointer, MSDOS.SYS does not, instead using the hardcoded
  5996.           address of the info record
  5997.  16h    DWORD    pointer to array of current directory structures
  5998.         (see #0930,#0931)
  5999.  1Ah    DWORD    pointer to system FCB tables (see #0927,#0928,#0929)
  6000.  1Eh    WORD    number of protected FCBs (the y in the CONFIG.SYS FCBS=x,y)
  6001.         (always 00h for DOS 5.0)
  6002.  20h    BYTE    number of block devices installed
  6003.  21h    BYTE    number of available drive letters (largest of 5, installed
  6004.           block devices, and CONFIG.SYS LASTDRIVE=).  Also size of
  6005.           current directory structure array.
  6006.  22h 18 BYTEs    actual NUL device driver header (not a pointer!)
  6007.         NUL is always the first device on DOS's linked list of device
  6008.           drivers. (see #0933)
  6009.  34h    BYTE    number of JOIN'ed drives
  6010.  35h    WORD    pointer within IBMDOS code segment to list of special program
  6011.           names (see #0949)
  6012.         (always 0000h for DOS 5.0)
  6013.  37h    DWORD    pointer to FAR routine for resident IFS utility functions
  6014.         (see #0945)
  6015.         may be called by any IFS driver which does not wish to
  6016.           service functions 20h or 24h-28h itself
  6017.  3Bh    DWORD    pointer to chain of IFS (installable file system) drivers
  6018.  3Fh    WORD    the x in BUFFERS x,y (rounded up to multiple of 30 if in EMS)
  6019.  41h    WORD    number of lookahead buffers (the y in BUFFERS x,y)
  6020.  43h    BYTE    boot drive (1=A:)
  6021.  44h    BYTE    flag: 01h to use DWORD moves (80386+), 00h otherwise
  6022.  45h    WORD    extended memory size in KB
  6023. ---DOS 5.0-6.0---
  6024.  10h 39 BYTEs    as for DOS 4.x (see above)
  6025.  37h    DWORD    pointer to SETVER program list or 0000h:0000h
  6026.  3Bh    WORD    (DOS=HIGH) offset in DOS CS of function to fix A20 control
  6027.           when executing special .COM format
  6028.  3Dh    WORD    PSP of most-recently EXECed program if DOS in HMA, 0000h if low
  6029.         used for maintaining count of INT 21 calls which disable A20
  6030.           on return
  6031.  3Fh  8 BYTEs    as for DOS 4.x (see above)
  6032. ---Windows NT DOS Box---
  6033.  10h  6 BYTEs    ???
  6034.  16h    DWORD    pointer to array of current directory structures (see #0932)
  6035.  1Ah  6 BYTEs    ???
  6036.  20h    BYTE    number of block devices installed
  6037.  21h    BYTE    number of local drive letters (= installed block devices)
  6038.         Also size of current directory structure array.
  6039.  22h 18 BYTEs    actual NUL device driver header (not a pointer!)
  6040.         NUL is always the first device on DOS's linked list of device
  6041.           drivers. (see #0933)
  6042.  
  6043. Format of DOS memory control block:
  6044. Offset    Size    Description    (Table 0915)
  6045.  00h    BYTE    block type: 5Ah if last block in chain, otherwise 4Dh
  6046.  01h    WORD    PSP segment of owner or special flag value (see #0916)
  6047.  03h    WORD    size of memory block in paragraphs
  6048.  05h  3 BYTEs    unused by MS-DOS
  6049.         (386MAX) if locked-out block, region start/prev region end
  6050. ---DOS 2.x,3.x---
  6051.  08h  8 BYTEs    unused
  6052. ---DOS 4.0+ ---
  6053.  08h  8 BYTEs    ASCII program name if PSP memory block or DR DOS UMB,
  6054.           else garbage
  6055.         null-terminated if less than 8 characters
  6056. Notes:    the next MCB is at segment (current + size + 1)
  6057.     under DOS 3.1+, the first memory block is the DOS data segment,
  6058.       containing installable drivers, buffers, etc.     Under DOS 4.0+ it is
  6059.       divided into subsegments, each with its own memory control block
  6060.       (see #0920), the first of which is at offset 0000h.
  6061.     for DOS 5+, blocks owned by DOS may have either "SC" or "SD" in bytes
  6062.       08h and 09h.    "SC" is system code or locked-out inter-UMB memory,
  6063.       "SD" is system data, device drivers, etc.
  6064.     Some versions of DR DOS use only seven characters of the program name,
  6065.       placing a NUL in the eighth byte.
  6066. SeeAlso: #0917,#0919,#0920
  6067.  
  6068. (Table 0916)
  6069. Values for special flag PSP segments:
  6070.  0000h    free
  6071.  0006h    DR DOS XMS UMB
  6072.  0007h    DR DOS excluded upper memory ("hole")
  6073.  0008h    belongs to DOS
  6074.  FFF7h    386MAX v6.01+ ???
  6075.  FFFAh    386MAX UMB control block (see #0771 at AX=4402h"386MAX")
  6076.  FFFDh    386MAX locked-out memory
  6077.  FFFEh    386MAX UMB (normally immediately follows its control block)
  6078.  FFFFh    386MAX v6.01+ device driver
  6079.  
  6080. Format of MS-DOS 5+ UMB control block:
  6081. Offset    Size    Description    (Table 0917)
  6082.  00h    BYTE    type: 5Ah if last block in chain, 4Dh otherwise
  6083.  01h    WORD    first available paragraph in UMB if control block at start
  6084.           of UMB, 000Ah if control block at end of UMB
  6085.  03h    WORD    length in paragraphs of following UMB or locked-out region
  6086.  05h  3 BYTEs    unused
  6087.  08h  8 BYTEs    block type name: "UMB" if start block, "SM" if end block in UMB
  6088. SeeAlso: #0915,#0918
  6089.  
  6090. Format of MS-DOS 7.0 HMA memory control block:
  6091. Offset    Size    Description    (Table 0918)
  6092.  00h    WORD    signature "MS" (4Dh 53h)
  6093.  02h    WORD    usage flag???
  6094.         0000h free
  6095.         else ???
  6096.  04h    WORD    size of memory block in bytes (not counting MCB)
  6097.  06h    WORD    offset of next memory block in HMA or 0000h
  6098.  08h  8 BYTEs    unused (0)
  6099. SeeAlso: #0915,#0917,#0919
  6100.  
  6101. Format of STARLITE (General Software's Embedded DOS) memory control block:
  6102. Offset    Size    Description    (Table 0919)
  6103.  00h    BYTE    block type: 5Ah if last block in chain, otherwise 4Dh
  6104.  01h    WORD    PSP segment of owner, 0000h if free, 0008h if belongs to DOS
  6105.  03h    WORD    size of memory block in paragraphs
  6106.  05h    BYTE    unused
  6107.  06h    WORD    segment address of next memory control block (0000h if last)
  6108.  08h    WORD    segment address of previous memory control block or 0000h
  6109.  0Ah  6 BYTEs    reserved
  6110.  
  6111. Format of DOS 4.0+ data segment subsegment control blocks:
  6112. Offset    Size    Description    (Table 0920)
  6113.  00h    BYTE    subsegment type (blocks typically appear in this order)
  6114.         "D"  device driver
  6115.         "E"  device driver appendage
  6116.         "I"  IFS (Installable File System) driver
  6117.         "F"  FILES=  control block storage area (for FILES>5)
  6118.         "X"  FCBS=   control block storage area, if present
  6119.         "C"  BUFFERS EMS workspace area (if BUFFERS /X option used)
  6120.         "B"  BUFFERS=  storage area
  6121.         "L"  LASTDRIVE=     current directory structure array storage area
  6122.         "S"  STACKS=  code and data area, if present (see #0921,#0922)
  6123.         "T"  INSTALL= transient code
  6124.  01h    WORD    paragraph of subsegment start (usually the next paragraph)
  6125.  03h    WORD    size of subsegment in paragraphs
  6126.  05h  3 BYTEs    unused
  6127.  08h  8 BYTEs    for types "D" and "I", base name of file from which the driver
  6128.           was loaded (unused for other types)
  6129.  
  6130. Format of data at start of STACKS code segment (if present):
  6131. Offset    Size    Description    (Table 0921)
  6132.  00h    WORD    ???
  6133.  02h    WORD    number of stacks (the x in STACKS=x,y)
  6134.  04h    WORD    size of stack control block array (should be 8*x)
  6135.  06h    WORD    size of each stack (the y in STACKS=x,y)
  6136.  08h    DWORD    pointer to STACKS data segment
  6137.  0Ch    WORD    offset in STACKS data segment of stack control block array
  6138.  0Eh    WORD    offset in STACKS data segment of last element of that array
  6139.  10h    WORD    offset in STACKS data segment of the entry in that array for
  6140.           the next stack to be allocated (initially same as value in
  6141.           0Eh and works its way down in steps of 8 to the value in
  6142.           0Ch as hardware interrupts pre-empt each other)
  6143. Note:    the STACKS code segment data may, if present, be located as follows:
  6144.     DOS 3.2:    The code segment data is at a paragraph boundary fairly early
  6145.           in the IBMBIO segment (seen at 0070:0190h)
  6146.     DOS 3.3:    The code segment is at a paragraph boundary in the DOS data
  6147.           segment, which may be determined by inspecting the segment
  6148.           pointers of the vectors for those of interrupts 02h, 08h-0Eh,
  6149.           70h, 72-77h which have not been redirected by device drivers
  6150.           or TSRs.
  6151.     DOS 4.0+    Identified by sub-segment control block type "S" within the DOS
  6152.           data segment.
  6153. SeeAlso: #0923,INT B4"STACKMAN"
  6154.  
  6155. Format of array elements in STACKS data segment:
  6156. Offset    Size    Description    (Table 0922)
  6157.  00h    BYTE    status: 00h=free, 01h=in use, 03h=corrupted by overflow of
  6158.           higher stack.
  6159.  01h    BYTE    not used
  6160.  02h    WORD    previous SP
  6161.  04h    WORD    previous SS
  6162.  06h    WORD    ptr to word at top of stack (new value for SP). The word at the
  6163.           top of the stack is preset to point back to this control
  6164.           block.
  6165.  
  6166. Format of SHARE.EXE hooks (DOS 3.1-6.00):
  6167. Offset    Size    Description    (Table 0923)
  6168. (offsets from first system file table--pointed at by ListOfLists+04h)
  6169. -3Ch    DWORD    pointer to FAR routine for ???
  6170.         Note: not called by MS-DOS 3.3, set to 0000h:0000h by
  6171.             SHARE 3.3+
  6172. -38h    DWORD    pointer to FAR routine called on opening file
  6173.         on call, internal DOS location points at filename
  6174.           (see #0967 at AX=5D06h)
  6175.         Return: CF clear if successful
  6176.             CF set on error
  6177.                 AX = DOS error code (24h) (see #0960 at AH=59h)
  6178.         Note: SHARE directly accesses DOS-internal data to get name of
  6179.             file just opened
  6180. -34h    DWORD    pointer to FAR routine called on closing file
  6181.         ES:DI -> system file table
  6182.         Note: does something to every Record Lock Record for file
  6183. -30h    DWORD    pointer to FAR routine to close all files for given computer
  6184.         (called by AX=5D03h)
  6185. -2Ch    DWORD    pointer to FAR routine to close all files for given process
  6186.         (called by AX=5D04h)
  6187. -28h    DWORD    pointer to FAR routine to close file by name
  6188.         (called by AX=5D02h)
  6189.         DS:SI -> DOS parameter list (see #0966 at AX=5D00h)
  6190.            DPL's DS:DX -> name of file to close
  6191.         Return: CF clear if successful
  6192.             CF set on error
  6193.                 AX = DOS error code (03h) (see #0960 at AH=59h)
  6194. -24h    DWORD    pointer to FAR routine to lock region of file
  6195.         call with BX = file handle
  6196.               ---DOS 3.x---
  6197.               CX:DX = starting offset
  6198.               SI:AX = size
  6199.               ---DOS 4.0+ ---
  6200.               DS:DX -> lock range
  6201.                     DWORD start offset
  6202.                     DWORD size in bytes
  6203.         Return: CF set on error
  6204.                 AL = DOS error code (21h) (see #0960 at AH=59h)
  6205.         Note: not called if file is marked as remote
  6206. -20h    DWORD    pointer to FAR routine to unlock region of file
  6207.         call with BX = file handle
  6208.               ---DOS 3.x---
  6209.               CX:DX = starting offset
  6210.               SI:AX = size
  6211.               ---DOS 4.0+ ---
  6212.               DS:DX -> lock range
  6213.                     DWORD start offset
  6214.                     DWORD size in bytes
  6215.         Return: CF set on error
  6216.                 AL = DOS error code (21h) (see #0960 at AH=59h)
  6217.         Note: not called if file is marked as remote
  6218. -1Ch    DWORD    pointer to FAR routine to check if file region is locked
  6219.         call with ES:DI -> system file table entry for file
  6220.             CX = length of region from current position in file
  6221.         Return: CF set if any portion of region locked
  6222.                 AX = 0021h
  6223. -18h    DWORD    pointer to FAR routine to get open file list entry
  6224.         (called by AX=5D05h)
  6225.         call with DS:SI -> DOS parameter list (see #0966 at AX=5D00h)
  6226.             DPL's BX = index of sharing record
  6227.             DPL's CX = index of SFT in SFT chain of sharing rec
  6228.         Return: CF set on error or not loaded
  6229.                 AX = DOS error code (12h) (see #0960 at AH=59h)
  6230.             CF clear if successful
  6231.                 ES:DI -> filename
  6232.                 CX = number of locks owned by specified SFT
  6233.                 BX = network machine number
  6234.                 DX destroyed
  6235. -14h    DWORD    pointer to FAR routine for updating FCB from SFT???
  6236.         call with DS:SI -> unopened FCB
  6237.               ES:DI -> system file table entry
  6238.         Return: BL = C0h???
  6239.         Note: copies following fields from SFT to FCB:
  6240.            starting cluster of file      0Bh     1Ah
  6241.            sharing record offset      33h     1Ch
  6242.            file attribute          04h     1Eh
  6243. -10h    DWORD    pointer to FAR routine to get first cluster of FCB file ???
  6244.         call with ES:DI -> system file table entry
  6245.               DS:SI -> FCB
  6246.         Return: CF set if SFT closed or sharing record offsets
  6247.                 mismatched
  6248.             CF clear if successful
  6249.                 BX = starting cluster number from FCB
  6250. -0Ch    DWORD    pointer to FAR routine to close file if duplicate for process
  6251.         DS:SI -> system file table
  6252.         Return: AX = number of handle in JFT which already uses SFT
  6253.         Note: called during open/create of a file
  6254.         Note: if SFT was opened with inheritance enabled and sharing
  6255.             mode 111, does something to all other SFTs owned by
  6256.             same process which have the same file open mode and
  6257.             sharing record
  6258. -08h    DWORD    pointer to FAR routine for closing file
  6259.         Note: closes various handles referring to file most-recently
  6260.             opened
  6261. -04h    DWORD    pointer to FAR routine to update directory info in related SFT
  6262.           entries
  6263.         call with ES:DI -> system file table entry for file (see #0928)
  6264.               AX = subfunction (apply to each related SFT)
  6265.                 00h: update time stamp (offset 0Dh) and date
  6266.                      stamp (offset 0Fh)
  6267.                 01h: update file size (offset 11h) and starting
  6268.                      cluster (offset 0Bh).  Sets last-accessed
  6269.                      cluster fields to start of file if file
  6270.                      never accessed
  6271.                 02h: as function 01h, but last-accessed fields
  6272.                      always changed
  6273.                 03h: do both functions 00h and 02h
  6274.         Note: follows ptr at offset 2Bh in system file table entries
  6275.         Note: NOP if opened with no-inherit or via FCB
  6276. Notes:    most of the above hooks (except -04h, -14h, -18h, and -3Ch) assume
  6277.       either that SS=DOS DS or SS=DS=DOS DS and directly access
  6278.       DOS-internal data
  6279.     sharing hooks are not supported by DR DOS 5-6; they appear to be
  6280.       supported by Novell DOS 7, with a segment of 0000h indicating the
  6281.       DOS data segment
  6282. SeeAlso: #0924,#0925
  6283.  
  6284. Format of sharing record:
  6285. Offset    Size    Description    (Table 0924)
  6286.  00h    BYTE    flag
  6287.         00h free block
  6288.         01h allocated block
  6289.         FFh end marker
  6290.  01h    WORD    size of block
  6291.  03h    BYTE    checksum of pathname (including NUL)
  6292.         if sum of ASCII values is N, checksum is (N/256 + N%256)
  6293.  04h    WORD    offset in SHARE's DS of first Record Lock Record (see #0925)
  6294.  06h    DWORD    pointer to start of system file table chain for file
  6295.  0Ah    WORD    unique sequence number
  6296.  0Ch    var    ASCIZ full pathname
  6297. Note:    not supported by DR DOS SHARE 1.1 and 2.0; will reportedly be
  6298.       supported by Novell DOS 7
  6299. SeeAlso: #0923,#0925
  6300.  
  6301. Format of SHARE.EXE Record Lock Record:
  6302. Offset    Size    Description    (Table 0925)
  6303.  00h    WORD    offset in SHARE's DS of next lock table in list or 0000h
  6304.  02h    DWORD    offset in file of start of locked region
  6305.  06h    DWORD    offset in file of end of locked region
  6306.  0Ah    DWORD    pointer to System File Table entry for this file
  6307.  0Eh    WORD    PSP segment of lock's owner
  6308. ---DOS 5+ ---
  6309.  10h    WORD    lock type: (00h lock all, 01h lock writes only)
  6310. SeeAlso: #0923,#0924,#0926,#0929
  6311.  
  6312. Format of DOS 2.x system file tables:
  6313. Offset    Size    Description    (Table 0926)
  6314.  00h    DWORD    pointer to next file table (offset FFFFh if last)
  6315.  04h    WORD    number of files in this table
  6316.  06h  28h bytes per file
  6317.     Offset    Size    Description
  6318.      00h    BYTE    number of file handles referring to this file
  6319.      01h    BYTE    file open mode (see #0701 at AH=3Dh)
  6320.      02h    BYTE    file attribute
  6321.      03h    BYTE    drive (0 = character device, 1 = A, 2 = B, etc)
  6322.      04h 11 BYTEs    filename in FCB format (no path,no period,blank-padded)
  6323.      0Fh    WORD    ???
  6324.      11h    WORD    ???
  6325.      13h    DWORD    file size???
  6326.      17h    WORD    file date in packed format (see #0952 at AX=5700h)
  6327.      19h    WORD    file time in packed format (see #0951 at AX=5700h)
  6328.      1Bh    BYTE    device attribute (see #0720 at AX=4400h)
  6329.     ---character device---
  6330.      1Ch    DWORD    pointer to device driver
  6331.     ---block device---
  6332.      1Ch    WORD    starting cluster of file
  6333.      1Eh    WORD    relative cluster in file of last cluster accessed
  6334.     ------
  6335.      20h    WORD    absolute cluster number of current cluster
  6336.      22h    WORD    ???
  6337.      24h    DWORD    current file position???
  6338. SeeAlso: #0927,#0928,#0929
  6339.  
  6340. Format of DOS 3.0 system file tables and FCB tables:
  6341. Offset    Size    Description    (Table 0927)
  6342.  00h    DWORD    pointer to next file table (offset FFFFh if last)
  6343.  04h    WORD    number of files in this table
  6344.  06h  38h bytes per file
  6345.     Offset    Size    Description
  6346.      00h-1Eh as for DOS 3.1+ (see #0928)
  6347.      1Fh    WORD    byte offset of directory entry within sector
  6348.      21h 11 BYTEs    filename in FCB format (no path/period, blank-padded)
  6349.      2Ch    DWORD    (SHARE.EXE) pointer to previous SFT sharing same file
  6350.      30h    WORD    (SHARE.EXE) network machine number which opened file
  6351.             (Windows Enhanced mode DOSMGR uses the virtual machine
  6352.               ID as the machine number; see INT 2F/AX=1683h)
  6353.      32h    WORD    PSP segment of file's owner (first three entries for
  6354.               AUX/CON/PRN contain segment of IO.SYS startup code)
  6355.      34h    WORD    (SHARE.EXE) offset in SHARE code seg of share record
  6356.      36h    WORD    ??? apparently always 0000h
  6357. SeeAlso: #0926,#0928,#0929
  6358.  
  6359. Format of DOS 3.1-3.3x, DR DOS 5.0-6.0 system file tables and FCB tables:
  6360. Offset    Size    Description    (Table 0928)
  6361.  00h    DWORD    pointer to next file table (offset FFFFh if last)
  6362.  04h    WORD    number of files in this table
  6363.  06h  35h bytes per file
  6364.     Offset    Size    Description
  6365.      00h    WORD    number of file handles referring to this file
  6366.      02h    WORD    file open mode (see AX=6C00h, #0701 at AH=3Dh)
  6367.             bit 15 set if this file opened via FCB
  6368.      04h    BYTE    file attribute (see #0717 at AX=4301h)
  6369.      05h    WORD    device info word (see #0720 at AX=4400h)
  6370.             bit 15 set if remote file
  6371.             bit 14 set means do not set file date/time on closing
  6372.             bit 12 set means don't inherit on EXEC
  6373.             bits 5-0 drive number for disk files
  6374.      07h    DWORD    pointer to device driver header if character device
  6375.             else pointer to DOS Drive Parameter Block
  6376.               (see #0694 at AH=32h)
  6377.      0Bh    WORD    starting cluster of file
  6378.      0Dh    WORD    file time in packed format (see #0951 at AX=5700h)
  6379.             not used for character devices in DR DOS
  6380.      0Fh    WORD    file date in packed format (see #0952 at AX=5700h)
  6381.             not used for character devices in DR DOS
  6382.      11h    DWORD    file size
  6383.     ---system file table---
  6384.      15h    DWORD    current offset in file (may be larger than size of
  6385.               file; INT 21/AH=42h does not check new position)
  6386.     ---FCB table---
  6387.      15h    WORD    counter for last I/O to FCB
  6388.      17h    WORD    counter for last open of FCB
  6389.             (these are separate to determine the times of the
  6390.               latest I/O and open)
  6391.     ---
  6392.      19h    WORD    relative cluster within file of last cluster accessed
  6393.      1Bh    WORD    absolute cluster number of last cluster accessed
  6394.             0000h if file never read or written???
  6395.      1Dh    WORD    number of sector containing directory entry
  6396.      1Fh    BYTE    number of dir entry within sector (byte offset/32)
  6397.      20h 11 BYTEs    filename in FCB format (no path/period, blank-padded)
  6398.      2Bh    DWORD    (SHARE.EXE) pointer to previous SFT sharing same file
  6399.      2Fh    WORD    (SHARE.EXE) network machine number which opened file
  6400.             (Windows Enhanced mode DOSMGR uses the virtual machine
  6401.               ID as the machine number; see INT 2F/AX=1683h)
  6402.      31h    WORD    PSP segment of file's owner (see #0677 at AH=26h)
  6403.               (first three entries for AUX/CON/PRN contain segment
  6404.               of IO.SYS startup code)
  6405.      33h    WORD    offset within SHARE.EXE code segment of
  6406.               sharing record (see #0924)  0000h = none
  6407. SeeAlso: #0926,#0927,#0929
  6408.  
  6409. Format of DOS 4.0-6.0 system file tables and FCB tables:
  6410. Offset    Size    Description    (Table 0929)
  6411.  00h    DWORD    pointer to next file table (offset FFFFh if last)
  6412.  04h    WORD    number of files in this table
  6413.  06h  3Bh bytes per file
  6414.     Offset    Size    Description
  6415.      00h    WORD    number of file handles referring to this file
  6416.             FFFFh if in use but not referenced
  6417.      02h    WORD    file open mode (see AX=6C00h,#0701 at AH=3Dh)
  6418.             bit 15 set if this file opened via FCB
  6419.      04h    BYTE    file attribute (see #0717 at AX=4301h)
  6420.      05h    WORD    device info word (see also #0720 at AX=4400h)
  6421.             bit 15 set if remote file
  6422.             bit 14 set means do not set file date/time on closing
  6423.             bit 13 set if named pipe
  6424.             bit 12 set if no inherit
  6425.             bit 11 set if network spooler
  6426.             bit 7  set if device, clear if file (only if local)
  6427.             bits 6-0 as for AX=4400h
  6428.      07h    DWORD    pointer to device driver header if character device
  6429.             else pointer to DOS Drive Parameter Block
  6430.               (see #0694 at AH=32h) or REDIR data
  6431.      0Bh    WORD    starting cluster of file (local files only)
  6432.      0Dh    WORD    file time in packed format (see #0951)
  6433.      0Fh    WORD    file date in packed format (see #0952)
  6434.      11h    DWORD    file size
  6435.      15h    DWORD    current offset in file (SFT)
  6436.             LRU counters (FCB table, two WORDs)
  6437.     ---local file---
  6438.      19h    WORD    relative cluster within file of last cluster accessed
  6439.      1Bh    DWORD    number of sector containing directory entry
  6440.      1Fh    BYTE    number of dir entry within sector (byte offset/32)
  6441.     ---network redirector---
  6442.      19h    DWORD    pointer to REDIRIFS record
  6443.      1Dh  3 BYTEs    ???
  6444.     ------
  6445.      20h 11 BYTEs    filename in FCB format (no path/period, blank-padded)
  6446.      2Bh    DWORD    (SHARE.EXE) pointer to previous SFT sharing same file
  6447.      2Fh    WORD    (SHARE.EXE) network machine number which opened file
  6448.             (Windows Enhanced mode DOSMGR uses the virtual machine
  6449.               ID as the machine number; see INT 2F/AX=1683h)
  6450.      31h    WORD    PSP segment of file's owner (see #0677 at AH=26h)
  6451.               (first three entries for AUX/CON/PRN contain segment
  6452.               of IO.SYS startup code)
  6453.      33h    WORD    offset within SHARE.EXE code segment of
  6454.             sharing record (see #0882)  0000h = none
  6455.      35h    WORD    (local) absolute cluster number of last clustr accessed
  6456.             (redirector) ???
  6457.      37h    DWORD    pointer to IFS driver for file, 0000000h if native DOS
  6458. Note:    the OS/2 2.0 DOS Boot Session does not properly fill in the filename
  6459.       field due to incomplete support for SFTs; the OS/2 2.0 DOS Window
  6460.       does not appear to support SFTs at all
  6461. SeeAlso: #0926,#0927,#0928
  6462.  
  6463. Format of current directory structure (CDS) (array, LASTDRIVE entries):
  6464. Offset    Size    Description    (Table 0930)
  6465.  00h 67 BYTEs    ASCIZ path in form X:\PATH (local) or UNC form
  6466.           \\SERVER\PATH (network, see notes below)
  6467.  43h    WORD    drive attributes (see also note below and AX=5F07h)
  6468.         bit 15: uses network redirector     \ invalid if 00, installable
  6469.         bit 14: physical drive         / file system if 11
  6470.         bit 13: JOIN'ed      \ path above is true path that would be
  6471.         bit 12: SUBST'ed  / needed if not under SUBST or JOIN
  6472.         bit  7: remote drive hidden from redirector's assign-list and
  6473.               exempt from network connection make/break commands;
  6474.               set for CD-ROM drives
  6475.  45h    DWORD    pointer to Drive Parameter Block for drive
  6476.           (see #0694 at AH=32h)
  6477. ---local drives---
  6478.  49h    WORD    starting cluster of current directory
  6479.         0000h = root, FFFFh = never accessed
  6480.  4Bh    WORD    ??? seems to be FFFFh always
  6481.  4Dh    WORD    ??? seems to be FFFFh always
  6482. ---network drives---
  6483.  49h    DWORD    pointer to redirector or REDIRIFS record, or FFFFh:FFFFh
  6484.         (DOS 4 only) available for use by IFS driver
  6485.  4Dh    WORD    stored user data from INT 21/AX=5F03h
  6486. ------
  6487.  4Fh    WORD    offset in current directory path of backslash corresponding to
  6488.           root directory for drive
  6489.         this value specifies how many characters to hide from the
  6490.           "CHDIR" and "GETDIR" calls; normally set to 2 to hide the
  6491.           drive letter and colon, SUBST, JOIN, and networks change it
  6492.           so that only the appropriate portion of the true path is
  6493.           visible to the user
  6494. ---DOS 4.0+ ---
  6495.  51h    BYTE    (DOS 4 only, remote drives) device type
  6496.         04h network drive
  6497.  52h    DWORD    pointer to IFS driver (DOS 4) or redirector block (DOS 5+) for
  6498.           this drive, 00000000h if native DOS
  6499.  56h    WORD    available for use by IFS driver
  6500. Notes:    the path for invalid drives is normally set to X:\, but may be empty
  6501.       after JOIN x: /D in DR DOS 5.0 or NET USE x: /D in older LAN versions
  6502.     normally, only one of bits 13&12 may be set together with bit 14, but
  6503.       DR DOS 5.0 uses other combinations for bits 15-12: 0111 JOIN,
  6504.       0001 SUBST, 0101 ASSIGN (see #0931)
  6505.     Windows for Workgroups 3.11 network sets the path to the local
  6506.       drive and directory even for network drives; in that case the
  6507.       UNC form \\SERVER\SHARE can be obtained with INT 21/AX=5F02h
  6508.       or INT 21/AX=5F46h. LapLink RemoteAccess does the same even for
  6509.       INT 21/AX=5F02h
  6510.     SoftWindows on the Macintosh PowerPC sets \\E for the host drive
  6511. SeeAlso: #0931
  6512.  
  6513. Format of DR DOS 5.0-6.0 current directory structure entry (array):
  6514. Offset    Size    Description    (Table 0931)
  6515.  00h 67 BYTEs    ASCIZ pathname of actual root directory for this logical drive
  6516.  43h    WORD    drive attributes
  6517.         1000h SUBSTed drive
  6518.         3000h??? JOINed drive
  6519.         4000h physical drive
  6520.         5000h ASSIGNed drive
  6521.         7000h JOINed drive
  6522.         8000h network drive
  6523.  45h    BYTE    physical drive number (0=A:) if this logical drive is valid
  6524.  46h    BYTE    ??? apparently flags for JOIN and ASSIGN
  6525.  47h    WORD    cluster number of start of parent directory (0000h = root)
  6526.  49h    WORD    entry number of current directory in parent directory
  6527.  4Bh    WORD    cluster number of start of current directory
  6528.  4Dh    WORD    used for media change detection (details not available)
  6529.  4Fh    WORD    cluster number of SUBST/JOIN "root" directory
  6530.         0000h if physical root directory
  6531. SeeAlso: #0930
  6532.  
  6533. Format of Windows NT Current Directory Structure (CDS) (array):
  6534. Offset    Size    Description    (Table 0932)
  6535.  00h 67 BYTEs    ASCIZ path in form X:\ (does not show either current directory
  6536.           or network path)
  6537.  43h  4 BYTEs    ???
  6538. Note:    the WinNT CDS contains only as many entries as there are local drives,
  6539.       not LASTDRIVE entries.
  6540.  
  6541. Format of DOS device driver header:
  6542. Offset    Size    Description    (Table 0933)
  6543.  00h    DWORD    pointer to next driver, offset=FFFFh if last driver
  6544.  04h    WORD    device attributes (see #0934,#0935)
  6545.  06h    WORD    device strategy entry point
  6546.         call with ES:BX -> request header
  6547.           (see #1845 at INT 2F/AX=0802h)
  6548.  08h    WORD    device interrupt entry point
  6549. ---character device---
  6550.  0Ah  8 BYTEs    blank-padded character device name
  6551. ---block device---
  6552.  0Ah    BYTE    number of subunits (drives) supported by driver
  6553.  0Bh  7 BYTEs    normally unused; sometimes contains signature to indicate
  6554.           specific drivers:
  6555.         "GFS    "   LapLink III device driver DD.BIN
  6556.         "STAC-CD"   Stacker/Stacker Anywhere (see AX=4404h"Stacker")
  6557.         "SIDExxx"   PCMCIA driver ATADRV.EXE (see AX=440Dh)
  6558.         "$PCMATA"   PCMCIA driver PCMATA.SYS (see AX=440Dh)
  6559.         "DSKREET"   NortonUtils v5+ Diskreet (see INT 2F/AX=FE00h)
  6560.         "DBLSPAC"   MS DoubleSpace or DriveSpace
  6561. ---DoubleSpace/DriveSpace---
  6562.  12h  2 BYTEs    signature ",." (2Ch 2Eh)
  6563.  14h    var    preloading API entry point
  6564. ---CD-ROM---
  6565.  12h    WORD    reserved, must be 0000h
  6566.         appears to be another device chain
  6567.  14h    BYTE    drive letter (must initially be 00h; this byte is set by
  6568.           MSCDEX when it loads)
  6569.  15h    BYTE    number of units
  6570.  16h  6 BYTEs    signature 'MSCDnn' where 'nn' is version (currently '00')
  6571. SeeAlso: #1803 at INT 25/AX=CDCDh,#2030 at INT 2F/AX=5600h
  6572.  
  6573. Bitfields for device attributes (character device):
  6574. Bit(s)    Description    (Table 0934)
  6575.  15    set (indicates character device)
  6576.  14    IOCTL supported (see AH=44h)
  6577.  13    (DOS 3.0+) output until busy supported
  6578.  12    reserved
  6579.  11    (DOS 3.0+) OPEN/CLOSE/RemMedia calls supported
  6580.  10-8    reserved
  6581.  7    (DOS 5.0+) Generic IOCTL check call supported (driver command 19h)
  6582.     (see AX=4410h,AX=4411h)
  6583.  6    (DOS 3.2+) Generic IOCTL call supported (driver command 13h)
  6584.     (see AX=440Ch,AX=440Dh)
  6585.  5    reserved
  6586.  4    device is special (use INT 29 "fast console output")
  6587.  3    device is CLOCK$ (all reads/writes use transfer record described
  6588.       below)
  6589.  2    device is NUL
  6590.  1    device is standard output
  6591.  0    device is standard input
  6592. Note:    for European MS-DOS 4.0, bit 11 also indicates that bits 8-6 contain a
  6593.       version code (000 = DOS 3.0,3.1; 001 = DOS 3.2;
  6594.       010 = European DOS 4.0)
  6595. SeeAlso: #0935,#0933
  6596.  
  6597. Bitfields for device attributes (block device):
  6598. Bit(s)    Description    (Table 0935)
  6599.  15    clear (indicates block device)
  6600.  14    IOCTL supported
  6601.  13    non-IBM format
  6602.  12    network device (device is remote)
  6603.  11    (DOS 3.0+) OPEN/CLOSE/RemMedia calls supported
  6604.  10    reserved
  6605.  9    direct I/O not allowed??? (set by DOS 3.3 DRIVER.SYS for "new" drives)
  6606.  8    ??? set by DOS 3.3 DRIVER.SYS for "new" drives
  6607.  7    (DOS 5.0+) Generic IOCTL check call supported (driver command 19h)
  6608.     (see AX=4410h,AX=4411h)
  6609.  6    (DOS 3.2+) Generic IOCTL call supported (driver command 13h)
  6610.     implies support for commands 17h and 18h
  6611.       (see AX=440Ch,AX=440Dh,AX=440Eh,AX=440Fh)
  6612.  5-2    reserved
  6613.  1    driver supports 32-bit sector addressing (DOS 3.31+)
  6614.  0     reserved
  6615. Note:    for European MS-DOS 4.0, bit 11 also indicates that bits 8-6 contain a
  6616.       version code (000 = DOS 3.0,3.1; 001 = DOS 3.2;
  6617.       010 = European DOS 4.0)
  6618. SeeAlso: #0934,#0933
  6619.  
  6620. Format of DOS 2.x disk buffer:
  6621. Offset    Size    Description    (Table 0936)
  6622.  00h    DWORD    pointer to next disk buffer, offset = FFFFh if last
  6623.         least-recently used buffer is first in chain
  6624.  04h    BYTE    drive (0=A, 1=B, etc), FFh if not in use
  6625.  05h  3 BYTEs    unused??? (seems always to be 00h 00h 01h)
  6626.  08h    WORD    logical sector number
  6627.  0Ah    BYTE    number of copies to write (1 for non-FAT sectors)
  6628.  0Bh    BYTE    sector offset between copies if multiple copies to be written
  6629.  0Ch    DWORD    pointer to DOS Drive Parameter Block (see #0694 at AH=32h)
  6630.  10h        buffered data
  6631. SeeAlso: #0937,#0939,#0940,#0942
  6632.  
  6633. Format of DOS 3.x disk buffer:
  6634. Offset    Size    Description    (Table 0937)
  6635.  00h    DWORD    pointer to next disk buffer, offset = FFFFh if last
  6636.         least-recently used buffer is first in chain
  6637.  04h    BYTE    drive (0=A,1=B, etc), FFh if not in use
  6638.  05h    BYTE    buffer flags (see #0938)
  6639.  06h    WORD    logical sector number
  6640.  08h    BYTE    number of copies to write (1 for non-FAT sectors)
  6641.  09h    BYTE    sector offset between copies if multiple copies to be written
  6642.  0Ah    DWORD    pointer to DOS Drive Parameter Block (see #0694 at AH=32h)
  6643.  0Eh    WORD    unused??? (almost always 0)
  6644.  10h        buffered data
  6645. SeeAlso: #0936,#0939,#0940,#0942
  6646.  
  6647. Bitfields for DOS 3.x disk buffer flags:
  6648. Bit(s)    Description    (Table 0938)
  6649.  7    ???
  6650.  6    buffer dirty
  6651.  5    buffer has been referenced
  6652.  4    ???
  6653.  3    sector in data area
  6654.  2    sector in a directory, either root or subdirectory
  6655.  1    sector in FAT
  6656.  0    boot sector??? (guess)
  6657. SeeAlso: #0943
  6658.  
  6659. Format of DOS 4.00 (pre UR 25066) disk buffer info:
  6660. Offset    Size    Description    (Table 0939)
  6661.  00h    DWORD    pointer to array of disk buffer hash chain heads (see #0941)
  6662.  04h    WORD    number of disk buffer hash chains (referred to as NDBCH below)
  6663.  06h    DWORD    pointer to lookahead buffer, zero if not present
  6664.  0Ah    WORD    number of lookahead sectors, else zero (the y in BUFFERS=x,y)
  6665.  0Ch    BYTE    00h if buffers in EMS (/X), FFh if not
  6666.  0Dh    WORD    EMS handle for buffers, zero if not in EMS
  6667.  0Fh    WORD    EMS physical page number used for buffers (usually 255)
  6668.  11h    WORD    ??? seems always to be 0001h
  6669.  13h    WORD    segment of EMS physical page frame
  6670.  15h    WORD    ??? seems always to be zero
  6671.  17h  4 WORDs    EMS partial page mapping information???
  6672. SeeAlso: #0936,#0937,#0940,#0944
  6673.  
  6674. Format of DOS 4.01 (from UR 25066 Corrctive Services Disk on) disk buffer info:
  6675. Offset    Size    Description    (Table 0940)
  6676.  00h    DWORD    pointer to array of disk buffer hash chain heads (see #0941)
  6677.  04h    WORD    number of disk buffer hash chains (referred to as NDBCH below)
  6678.  06h    DWORD    pointer to lookahead buffer, zero if not present
  6679.  0Ah    WORD    number of lookahead sectors, else zero (the y in BUFFERS=x,y)
  6680.  0Ch    BYTE    01h, possibly to distinguish from pre-UR 25066 format
  6681.  0Dh    WORD    ??? EMS segment for BUFFERS (only with /XD)
  6682.  0Fh    WORD    ??? EMS physical page number of EMS seg above (only with /XD)
  6683.  11h    WORD    ??? EMS segment for ??? (only with /XD)
  6684.  13h    WORD    ??? EMS physical page number of above (only with /XD)
  6685.  15h    BYTE    ??? number of EMS page frames present (only with /XD)
  6686.  16h    WORD    segment of one-sector workspace buffer allocated in main memory
  6687.           if BUFFERS/XS or /XD options in effect, possibly to avoid DMA
  6688.           into EMS
  6689.  18h    WORD    EMS handle for buffers, zero if not in EMS
  6690.  1Ah    WORD    EMS physical page number used for buffers (usually 255)
  6691.  1Ch    WORD    ??? appears always to be 0001h
  6692.  1Eh    WORD    segment of EMS physical page frame
  6693.  20h    WORD    ??? appears always to be zero
  6694.  22h    BYTE    00h if /XS, 01h if /XD, FFh if BUFFERS not in EMS
  6695. SeeAlso: #0936,#0937,#0939,#0944
  6696.  
  6697. Format of DOS 4.x disk buffer hash chain head (array, one entry per chain):
  6698. Offset    Size    Description    (Table 0941)
  6699.  00h    WORD    EMS logical page number in which chain is resident, -1 if not
  6700.           in EMS
  6701.  02h    DWORD    pointer to least recently used buffer header.  All buffers on
  6702.           this chain are in the same segment.
  6703.  06h    BYTE    number of dirty buffers on this chain
  6704.  07h    BYTE    reserved (00h)
  6705. Notes:    buffered disk sectors are assigned to chain N where N is the sector's
  6706.       address modulo NDBCH,     0 <= N <= NDBCH-1
  6707.     each chain resides completely within one EMS page
  6708.     this structure is in main memory even if buffers are in EMS
  6709.  
  6710. Format of DOS 4.0-6.0 disk buffer:
  6711. Offset    Size    Description    (Table 0942)
  6712.  00h    WORD    forward ptr, offset only, to next least recently used buffer
  6713.  02h    WORD    backward pointer, offset only
  6714.  04h    BYTE    drive (0=A,1=B, etc) if bit 7 clear
  6715.         SFT index if bit 7 set
  6716.         FFh if not in use
  6717.  05h    BYTE    buffer flags (see #0943)
  6718.  06h    DWORD    logical sector number (local buffers only)
  6719.  0Ah    BYTE    number of copies to write
  6720.         for FAT sectors, same as number of FATs
  6721.         for data and directory sectors, usually 1
  6722.  0Bh    WORD    offset in sectors between copies to write for FAT sectors
  6723.  0Dh    DWORD    pointer to DOS Drive Parameter Block (see #0694 at AH=32h)
  6724.  11h    WORD    size of data in buffer if remote buffer (see flags above)
  6725.  13h    BYTE    reserved (padding)
  6726.  14h        buffered data
  6727. Note:    for DOS 4.x, all buffered sectors which have the same hash value
  6728.       (computed as the sum of high and low words of the logical sector
  6729.       number divided by the number of disk buffer chains) are on the same
  6730.       doubly-linked circular chain; for DOS 5+, only a single circular
  6731.       chain exists.
  6732.     the links consist of offset addresses only, the segment being the same
  6733.       for all buffers in the chain.
  6734. SeeAlso: #0936,#0937,#0939
  6735.  
  6736. Bitfields for DOS 4.0-6.0 disk buffer flags:
  6737. Bit(s)    Description    (Table 0943)
  6738.  7    remote buffer
  6739.  6    buffer dirty
  6740.  5    buffer has been referenced (reserved in DOS 5+)
  6741.  4    search data buffer (only valid if remote buffer)
  6742.  3    sector in data area
  6743.  2    sector in a directory, either root or subdirectory
  6744.  1    sector in FAT
  6745.  0    reserved
  6746. SeeAlso: #0938
  6747.  
  6748. Format of DOS 5.0-6.0 disk buffer info:
  6749. Offset    Size    Description    (Table 0944)
  6750.  00h    DWORD    pointer to least-recently-used buffer header (may be in HMA)
  6751.         (see #0942)
  6752.  04h    WORD    number of dirty disk buffers
  6753.  06h    DWORD    pointer to lookahead buffer, zero if not present
  6754.  0Ah    WORD    number of lookahead sectors, else zero (the y in BUFFERS=x,y)
  6755.  0Ch    BYTE    buffer location
  6756.         00h base memory, no workspace buffer
  6757.         01h HMA, workspace buffer in base memory
  6758.  0Dh    DWORD    pointer to one-segment workspace buffer in base memory
  6759.  11h  3 BYTEs    unused
  6760.  14h    WORD    ???
  6761.  16h    BYTE    flag: INT 24 fail while making an I/O status call
  6762.  17h    BYTE    temp storage for user memory allocation strategy during EXEC
  6763.  18h    BYTE    counter: number of INT 21 calls for which A20 is off
  6764.  19h    BYTE    bit flags
  6765.         bit 0: ???
  6766.         bit 1: SWITCHES=/W specified in CONFIG.SYS (don't load
  6767.             WINA20.SYS when MS Windows 3.0 starts)
  6768.         bit 2: in EXEC state (INT 21/AX=4B05h)
  6769.  1Ah    WORD    offset of unpack code start (used only during INT 21/AX=4B05h)
  6770.  1Ch    BYTE    bit 0 set iff UMB MCB chain linked to normal MCB chain
  6771.  1Dh    WORD    minimum paragraphs of memory required by program being EXECed
  6772.  1Fh    WORD    segment of first MCB in upper memory blocks or FFFFh if DOS
  6773.           memory chain in base 640K only (first UMB MCB usually at
  6774.           9FFFh, locking out video memory with a DOS-owned memory
  6775.           block)
  6776.         the MCB this word points at contains a valid link into high
  6777.           memory even if it is marked with a 'Z' indicating the last
  6778.           memory block
  6779.  21h    WORD    paragraph from which to start scanning during memory allocation
  6780. SeeAlso: #0939,#0940
  6781.  
  6782. (Table 0945)
  6783. Call IFS utility function entry point with:
  6784.     AH = 20h miscellaneous functions
  6785.         AL = 00h get date
  6786.         Return: CX = year
  6787.             DH = month
  6788.             DL = day
  6789.         AL = 01h get process ID and computer ID
  6790.         Return: BX = current PSP segment
  6791.             DX = active network machine number
  6792.         AL = 05h get file system info
  6793.         ES:DI -> 16-byte info buffer
  6794.         Return: buffer filled
  6795.             Offset    Size    Description
  6796.              00h  2 BYTEs    unused
  6797.              02h    WORD    number of SFTs (actually counts only
  6798.                     the first two file table arrays)
  6799.              04h    WORD    number of FCB table entries
  6800.              06h    WORD    number of proctected FCBs
  6801.              08h  6 BYTEs    unused
  6802.              0Eh    WORD    largest sector size supported
  6803.         AL = 06h get machine name
  6804.         ES:DI -> 18-byte buffer for name
  6805.         Return: buffer filled with name starting at offset 02h
  6806.         AL = 08h get sharing retry count
  6807.         Return: BX = sharing retry count
  6808.         AL = other
  6809.         Return: CF set
  6810.     AH = 21h get redirection state
  6811.         BH = type (03h disk, 04h printer)
  6812.         Return: BH = state (00h off, 01h on)
  6813.     AH = 22h ??? some sort of time calculation
  6814.         AL = 00h ???
  6815.             nonzero ???
  6816.     AH = 23h ??? some sort of time calculation
  6817.     AH = 24h compare filenames
  6818.         DS:SI -> first ASCIZ filename
  6819.         ES:DI -> second ASCIZ filename
  6820.         Return: ZF set if files are same ignoring case and / vs \
  6821.     AH = 25h normalize filename
  6822.         DS:SI -> ASCIZ filename
  6823.         ES:DI -> buffer for result
  6824.         Return: filename uppercased, forward slashes changed to backslashes
  6825.     AH = 26h get DOS stack
  6826.         Return: DS:SI -> top of stack
  6827.             CX = size of stack in bytes
  6828.     AH = 27h increment InDOS flag
  6829.     AH = 28h decrement InDOS flag
  6830. Note:    IFS drivers which do not wish to implement functions 20h or 24h-28h may
  6831.       pass them on to the default handler pointed at by [LoL+37h]
  6832. SeeAlso: #0946,#0947
  6833.  
  6834. Format of IFS driver list:
  6835. Offset    Size    Description    (Table 0946)
  6836.  00h    DWORD    pointer to next driver header
  6837.  04h  8 BYTEs    IFS driver name (blank padded), as used by FILESYS command
  6838.  0Ch  4 BYTEs    ???
  6839.  10h    DWORD    pointer to IFS utility function entry point (see #0945)
  6840.         call with ES:BX -> IFS request (see #0947)
  6841.  14h    WORD    offset in header's segment of driver entry point
  6842.     ???
  6843. SeeAlso: #0945,#0947
  6844.  
  6845. Format of IFS request block:
  6846. Offset    Size    Description    (Table 0947)
  6847.  00h    WORD    total size in bytes of request
  6848.  02h    BYTE    class of request
  6849.         02h ???
  6850.         03h redirection
  6851.         04h ???
  6852.         05h file access
  6853.         06h convert error code to string
  6854.         07h ???
  6855.  03h    WORD    returned DOS error code
  6856.  05h    BYTE    IFS driver exit status
  6857.         00h success
  6858.         01h ???
  6859.         02h ???
  6860.         03h ???
  6861.         04h ???
  6862.         FFh internal failure
  6863.  06h 16 BYTEs    ???
  6864. ---request class 02h---
  6865.  16h    BYTE    function code
  6866.         04h ???
  6867.  17h    BYTE    unused???
  6868.  18h    DWORD    pointer to ???
  6869.  1Ch    DWORD    pointer to ???
  6870.  20h  2 BYTEs    ???
  6871. ---request class 03h---
  6872.  16h    BYTE    function code
  6873.  17h    BYTE    ???
  6874.  18h    DWORD    pointer to ???
  6875.  1Ch    DWORD    pointer to ???
  6876.  22h    WORD    returned ???
  6877.  24h    WORD    returned ???
  6878.  26h    WORD    returned ???
  6879.  28h    BYTE    returned ???
  6880.  29h    BYTE    unused???
  6881. ---request class 04h---
  6882.  16h    DWORD    pointer to ???
  6883.  1Ah    DWORD    pointer to ???
  6884. ---request class 05h---
  6885.  16h    BYTE    function code
  6886.         01h flush disk buffers
  6887.         02h get disk space
  6888.         03h MKDIR
  6889.         04h RMDIR
  6890.         05h CHDIR
  6891.         06h delete file
  6892.         07h rename file
  6893.         08h search directory
  6894.         09h file open/create
  6895.         0Ah LSEEK
  6896.         0Bh read from file
  6897.         0Ch write to file
  6898.         0Dh lock region of file
  6899.         0Eh commit/close file
  6900.         0Fh get/set file attributes
  6901.         10h printer control
  6902.         11h ???
  6903.         12h process termination
  6904.         13h ???
  6905.     ---class 05h function 01h---
  6906.      17h  7 BYTEs    ???
  6907.      1Eh    DWORD    pointer to ???
  6908.      22h  4 BYTEs    ???
  6909.      26h    BYTE    ???
  6910.      27h    BYTE    ???
  6911.     ---class 05h function 02h---
  6912.      17h  7 BYTEs    ???
  6913.      1Eh    DWORD    pointer to ???
  6914.      22h  4 BYTEs    ???
  6915.      26h    WORD    returned total clusters
  6916.      28h    WORD    returned sectors per cluster
  6917.      2Ah    WORD    returned bytes per sector
  6918.      2Ch    WORD    returned available clusters
  6919.      2Eh    BYTE    returned ???
  6920.      2Fh    BYTE    ???
  6921.     ---class 05h functions 03h,04h,05h---
  6922.      17h  7 BYTEs    ???
  6923.      1Eh    DWORD    pointer to ???
  6924.      22h  4 BYTEs    ???
  6925.      26h    DWORD    pointer to directory name
  6926.     ---class 05h function 06h---
  6927.      17h  7 BYTEs    ???
  6928.      1Eh    DWORD    pointer to ???
  6929.      22h  4 BYTEs    ???
  6930.      26h    WORD    attribute mask
  6931.      28h    DWORD    pointer to filename
  6932.     ---class 05h function 07h---
  6933.      17h  7 BYTEs    ???
  6934.      1Eh    DWORD    pointer to ???
  6935.      22h  4 BYTEs    ???
  6936.      26h    WORD    attribute mask
  6937.      28h    DWORD    pointer to source filespec
  6938.      2Ch    DWORD    pointer to destination filespec
  6939.     ---class 05h function 08h---
  6940.      17h  7 BYTEs    ???
  6941.      1Eh    DWORD    pointer to ???
  6942.      22h  4 BYTEs    ???
  6943.      26h    BYTE    00h FINDFIRST
  6944.             01h FINDNEXT
  6945.      28h    DWORD    pointer to FindFirst search data + 01h if FINDNEXT
  6946.      2Ch    WORD    search attribute if FINDFIRST
  6947.      2Eh    DWORD    pointer to filespec if FINDFIRST
  6948.     ---class 05h function 09h---
  6949.      17h  7 BYTEs    ???
  6950.      1Eh    DWORD    pointer to ???
  6951.      22h    DWORD    pointer to IFS open file structure (see #0948)
  6952.      26h    WORD    ???  \ together, specify open vs. create, whether or
  6953.      28h    WORD    ???  / not to truncate
  6954.      2Ah  4 BYTEs    ???
  6955.      2Eh    DWORD    pointer to filename
  6956.      32h  4 BYTEs    ???
  6957.      36h    WORD    file attributes on call
  6958.             returned ???
  6959.      38h    WORD    returned ???
  6960.     ---class 05h function 0Ah---
  6961.      17h  7 BYTEs    ???
  6962.      1Eh    DWORD    pointer to ???
  6963.      22h    DWORD    pointer to IFS open file structure (see #0948)
  6964.      26h    BYTE    seek type (02h = from end)
  6965.      28h    DWORD    offset on call
  6966.             returned new absolute position
  6967.     ---class 05h functions 0Bh,0Ch---
  6968.      17h  7 BYTEs    ???
  6969.      1Eh    DWORD    pointer to ???
  6970.      22h    DWORD    pointer to IFS open file structure (see #0948)
  6971.      28h    WORD    number of bytes to transfer
  6972.             returned bytes actually transferred
  6973.      2Ah    DWORD    transfer address
  6974.     ---class 05h function 0Dh---
  6975.      17h  7 BYTEs    ???
  6976.      1Eh    DWORD    pointer to ???
  6977.      22h    DWORD    pointer to IFS open file structure (see #0948)
  6978.      26h    BYTE    file handle???
  6979.      27h    BYTE    unused???
  6980.      28h    WORD    ???
  6981.      2Ah    WORD    ???
  6982.      2Ch    WORD    ???
  6983.      2Eh    WORD    ???
  6984.     ---class 05h function 0Eh---
  6985.      17h  7 BYTEs    ???
  6986.      1Eh    DWORD    pointer to ???
  6987.      22h    DWORD    pointer to IFS open file structure (see #0948)
  6988.      26h    BYTE    00h commit file
  6989.             01h close file
  6990.      27h    BYTE    unused???
  6991.     ---class 05h function 0Fh---
  6992.      17h  7 BYTEs    ???
  6993.      1Eh    DWORD    pointer to ???
  6994.      22h  4 BYTEs    ???
  6995.      26h    BYTE    02h GET attributes
  6996.             03h PUT attributes
  6997.      27h    BYTE    unused???
  6998.      28h 12 BYTEs    ???
  6999.      34h    WORD    search attributes???
  7000.      36h    DWORD    pointer to filename
  7001.      3Ah    WORD    (GET) returned ???
  7002.      3Ch    WORD    (GET) returned ???
  7003.      3Eh    WORD    (GET) returned ???
  7004.      40h    WORD    (GET) returned ???
  7005.      42h    WORD    (PUT) new attributes
  7006.             (GET) returned attributes
  7007.     ---class 05h function 10h---
  7008.      17h  7 BYTEs    ???
  7009.      1Eh    DWORD    pointer to ???
  7010.      22h    DWORD    pointer to IFS open file structure (see #0948)
  7011.      26h    WORD    ???
  7012.      28h    DWORD    pointer to ???
  7013.      2Ch    WORD    ???
  7014.      2Eh    BYTE    ???
  7015.      2Fh    BYTE    subfunction
  7016.             01h get printer setup
  7017.             03h ???
  7018.             04h ???
  7019.             05h ???
  7020.             06h ???
  7021.             07h ???
  7022.             21h set printer setup
  7023.     ---class 05h function 11h---
  7024.      17h  7 BYTEs    ???
  7025.      1Eh    DWORD    pointer to ???
  7026.      22h    DWORD    pointer to IFS open file structure (see #0948)
  7027.      26h    BYTE    subfunction
  7028.      27h    BYTE    unused???
  7029.      28h    WORD    ???
  7030.      2Ah    WORD    ???
  7031.      2Ch    WORD    ???
  7032.      2Eh    BYTE    ???
  7033.      2Fh    BYTE    ???
  7034.     ---class 05h function 12h---
  7035.      17h 15 BYTEs    unused???
  7036.      26h    WORD    PSP segment
  7037.      28h    BYTE    type of process termination
  7038.      29h    BYTE    unused???
  7039.     ---class 05h function 13h---
  7040.      17h 15 BYTEs    unused???
  7041.      26h    WORD    PSP segment
  7042. ---request class 06h---
  7043.  16h    DWORD    returned pointer to string corresponding to error code at 03h
  7044.  1Ah    BYTE    returned ???
  7045.  1Bh    BYTE    unused
  7046. ---request class 07h---
  7047.  16h    DWORD    pointer to IFS open file structure (see #0948)
  7048.  1Ah    BYTE    ???
  7049.  1Bh    BYTE    unused???
  7050. SeeAlso: #0946,#0945,#0948
  7051.  
  7052. Format of IFS open file structure:
  7053. Offset    Size    Description    (Table 0948)
  7054.  00h    WORD    ???
  7055.  02h    WORD    device info word
  7056.  04h    WORD    file open mode
  7057.  06h    WORD    ???
  7058.  08h    WORD    file attributes
  7059.  0Ah    WORD    owner's network machine number
  7060.  0Ch    WORD    owner's PSP segment
  7061.  0Eh    DWORD    file size
  7062.  12h    DWORD    current offset in file
  7063.  16h    WORD    file time
  7064.  18h    WORD    file date
  7065.  1Ah 11 BYTEs    filename in FCB format
  7066.  25h    WORD    ???
  7067.  27h    WORD    hash value of SFT address
  7068.         (low word of linear address + segment&F000h)
  7069.  29h  3 WORDs    network info from SFT
  7070.  2Fh    WORD    ???
  7071.  
  7072. Format of one item in DOS 4.0+ list of special program names:
  7073. Offset    Size    Description    (Table 0949)
  7074.  00h    BYTE    length of name (00h = end of list)
  7075.  01h  N BYTEs    name in format name.ext
  7076.  N    2 BYTEs    DOS version to return for program (major,minor)
  7077.         (see AH=30h,INT 2F/AX=122Fh)
  7078. ---DOS 4 only---
  7079.  N+2    BYTE    number of times to return fake version number (FFh = always)
  7080. Note:    if the name of the executable for the program making the DOS "get
  7081.       version" call matches one of the names in this list, DOS returns the
  7082.       specified version rather than the true version number
  7083. --------v-215252-----------------------------
  7084. INT 21 - VIRUS - "516"/"Leapfrog" - INSTALLATION CHECK
  7085.     AX = 5252h
  7086. Return: BX = FFEEh if resident
  7087. SeeAlso: AX=4BFFh"Cascade",AX=58CCh
  7088. --------D-2153-------------------------------
  7089. INT 21 - DOS 2+ internal - TRANSLATE BIOS PARAMETER BLOCK TO DRIVE PARAM BLOCK
  7090.     AH = 53h
  7091.     DS:SI -> BIOS Parameter Block (see #0950)
  7092.     ES:BP -> buffer for Drive Parameter Block (see #0694 at AH=32h)
  7093. Return: ES:BP buffer filled
  7094. Notes:    for DOS 3.0+, the cluster at which to start searching is set to 0000h
  7095.       and the number of free clusters is set to FFFFh (unknown)
  7096.     if the number of sectors per cluster is set to zero, MS-DOS will hang
  7097.       at startup because it computes the internally-used shift count by
  7098.       shifting this value right until the carry flag is set; since this
  7099.       will never happen when the field is zero, MS-DOS hangs
  7100.  
  7101. Format of BIOS Parameter Block:
  7102. Offset    Size    Description    (Table 0950)
  7103.  00h    WORD    number of bytes per sector
  7104.  02h    BYTE    number of sectors per cluster
  7105.  03h    WORD    number of reserved sectors at start of disk
  7106.  05h    BYTE    number of FATs
  7107.  06h    WORD    number of entries in root directory
  7108.  08h    WORD    total number of sectors
  7109.         for DOS 4.0+, set to zero if partition >32M, then set DWORD at
  7110.           15h to actual number of sectors
  7111.  0Ah    BYTE    media ID byte (see #0655)
  7112.  0Bh    WORD    number of sectors per FAT
  7113. ---DOS 2.13---
  7114.  0Dh    WORD    number of sectors per track
  7115.  0Fh    WORD    number of heads
  7116.  11h    WORD    number of hidden sectors
  7117. ---DOS 3.0+ ---
  7118.  0Dh    WORD    number of sectors per track
  7119.  0Fh    WORD    number of heads
  7120.  11h    DWORD    number of hidden sectors
  7121.  15h 11 BYTEs    reserved
  7122. ---DOS 4.0+ ---
  7123.  15h    DWORD    total number of sectors if word at 08h contains zero
  7124.  19h  6 BYTEs    ???
  7125.  1Fh    WORD    number of cylinders
  7126.  21h    BYTE    device type
  7127.  22h    WORD    device attributes (removable or not, etc)
  7128. ---DR DOS 5+ ---
  7129.  15h    DWORD    total number of sectors if word at 08h contains zero
  7130.  19h  6 BYTEs    reserved
  7131. ---European MS-DOS 4.00---
  7132.  15h    DWORD    total number of sectors if word at 08h contains zero
  7133.         (however, this DOS does not actually implement >32M partitions)
  7134. SeeAlso: #0694
  7135. --------D-2154-------------------------------
  7136. INT 21 - DOS 2+ - GET VERIFY FLAG
  7137.     AH = 54h
  7138. Return: AL = verify flag
  7139.         00h off
  7140.         01h on (all disk writes verified after writing)
  7141. SeeAlso: AH=2Eh
  7142. --------v-2154--BX4475-----------------------
  7143. INT 21 - VIRUS - "Dual_GtM"/"Ganeu" - INSTALLATION CHECK
  7144.     AH = 54h
  7145.     BX = 4475h ("Du")
  7146.     CX = 616Ch ("al")
  7147. Return: BX = 4774h ("Gt") and CX = 4D21h ("M!") if resident
  7148. SeeAlso: AX=50FDh"VIRUS",AX=5454h"VIRUS"
  7149. --------v-215454-----------------------------
  7150. INT 21 - VIRUS - "Dudley" - INSTALLATION CHECK
  7151.     AX = 5454h
  7152. Return: AX = 0000h if resident
  7153. SeeAlso: AX=50FDh"VIRUS",AH=54h/BX=4475h"VIRUS",AX=7BCEh"VIRUS"
  7154. --------D-2155-------------------------------
  7155. INT 21 - DOS 2+ internal - CREATE CHILD PSP
  7156.     AH = 55h
  7157.     DX = segment at which to create new PSP
  7158.     SI = (DOS 3.0+) value to place in memory size field at DX:[0002h]
  7159. Return: CF clear if successful
  7160. Notes:    creates a "child" PSP rather than making an exact copy of the current
  7161.       PSP; the new PSP's parent pointer is set to the current PSP and the
  7162.       reference count for each inherited file is incremented
  7163.     (DOS 2.0+) sets current PSP to DX
  7164.     (DOS 3.0+) marks "no inherit" file handles as closed in child PSP
  7165. BUG:    OS/2 Warp's DOS box does not clear CF on success, instead leaving it
  7166.       in its former state; to work around this, ensure that CF is clear
  7167.       before calling
  7168. SeeAlso: AH=26h,AH=50h
  7169. --------D-2156-------------------------------
  7170. INT 21 - DOS 2+ - "RENAME" - RENAME FILE
  7171.     AH = 56h
  7172.     DS:DX -> ASCIZ filename of existing file (no wildcards, but see below)
  7173.     ES:DI -> ASCIZ new filename (no wildcards)
  7174.     CL = attribute mask (server call only, see below)
  7175. Return: CF clear if successful
  7176.     CF set on error
  7177.         AX = error code (02h,03h,05h,11h) (see #0960)
  7178. Notes:    allows move between directories on same logical volume
  7179.     this function does not set the archive attribute
  7180.       (see #0717 at AX=4301h), which results in incremental backups not
  7181.       backing up the file under its new name
  7182.     open files should not be renamed
  7183.     (DOS 3.0+) allows renaming of directories
  7184.     (DOS 3.1+) wildcards are allowed if invoked via AX=5D00h, in which case
  7185.       error 12h (no more files) is returned on success, and both source and
  7186.       destination specs must be canonical (as returned by AH=60h).
  7187.       Wildcards in the destination are replaced by the corresponding char
  7188.       of each source file being renamed.  Under DOS 3.x, the call will fail
  7189.       if the destination wildcard is *.* or equivalent; under DR DOS 5.0,
  7190.       the call will fail if any wildcards are used.     When invoked via
  7191.       AX=5D00h, only those files matching the attribute mask in CL are
  7192.       renamed.
  7193.     under the FlashTek X-32 DOS extender, the old-name pointer is in DS:EDX
  7194.       and the new-name pointer is in ES:EDI (DS must equal ES)
  7195.     (DOS 2.x only) this function renames file by creating a new directory
  7196.       entry with the new name,then marking the old entry deleted
  7197. BUG:    under DR DOS 3.41, this function will generate a new directory entry
  7198.       with the new name (including any wildcards) which can only be removed
  7199.       with a sector editor when invoked via AX=5D00h
  7200. SeeAlso: AH=17h,AX=4301h,AX=5D00h,AH=60h,AH=71h,AX=F257h/SF=04h
  7201. --------v-215643------------------------
  7202. INT 21 - VIRUS - "PS-MPC.Gold" - INSTALLATION CHECK
  7203.     AX = 5643h  ('VC')
  7204. Return: AX = 5053h  ('PS') if resident
  7205. SeeAlso: AX=33E0h"VIRUS",AX=6303h"VIRUS"
  7206. --------D-215700-----------------------------
  7207. INT 21 - DOS 2+ - GET FILE'S DATE AND TIME
  7208.     AX = 5700h
  7209.     BX = file handle
  7210. Return: CF clear if successful
  7211.         CX = file's time (see #0951)
  7212.         DX = file's date (see #0952)
  7213.     CF set on error
  7214.         AX = error code (01h,06h) (see #0960)
  7215. Note:    under DR DOS 3.41 and 5.0, this function returns 0 (no date/time) for
  7216.       character devices; MS-DOS returns date and time of opening
  7217. SeeAlso: AX=5701h
  7218.  
  7219. Bitfields for file time:
  7220. Bit(s)    Description    (Table 0951)
  7221.  15-11    hours (0-23)
  7222.  10-5    minutes
  7223.  4-0    seconds/2
  7224.  
  7225. Bitfields for file date:
  7226. Bit(s)    Description    (Table 0952)
  7227.  15-9    year - 1980
  7228.  8-5    month
  7229.  4-0    day
  7230. --------D-215701-----------------------------
  7231. INT 21 - DOS 2+ - SET FILE'S DATE AND TIME
  7232.     AX = 5701h
  7233.     BX = file handle
  7234.     CX = new time (see #0951)
  7235.     DX = new date (see #0952)
  7236. Return: CF clear if successful
  7237.     CF set on error
  7238.         AX = error code (01h,06h) (see #0960)
  7239. SeeAlso: AX=5700h
  7240. --------D-215702-----------------------------
  7241. INT 21 - DOS 4.x only - GET EXTENDED ATTRIBUTES FOR FILE
  7242.     AX = 5702h
  7243.     BX = file handle
  7244.     CX = size of result buffer or 0000h
  7245.     DS:SI -> EAP list (see #0953)
  7246.     ES:DI -> buffer for returned EAV list (see #0956)
  7247. Return: CF clear if successful
  7248.         CX = size of returned data
  7249.     CF set on error
  7250.         AX = error code (see #0960)
  7251. Desc:    get the current value of one or more extended attributes
  7252. Notes:    if CX=0000h on entry, ES:DI is ignored and no data is actually
  7253.       returned, only the amount of data which is available
  7254.     the default DOS 4 behavior is to return a single word of 0000h (no
  7255.       structures) in the result buffer if CX>=0002h on entry
  7256. SeeAlso: AX=5703h,AX=5704h,AH=6Eh,INT 2F/AX=112Dh
  7257.  
  7258. Format of EAP (extended attribute properties) list:
  7259. Offset    Size    Description    (Table 0953)
  7260.  00h    WORD    number of EAP structures following
  7261.  02h    var    array of EAP structures (see #0954)
  7262. SeeAlso: #0956
  7263.  
  7264. Format of EAP (extended attribute property) structure:
  7265. Offset    Size    Description    (Table 0954)
  7266.  00h    BYTE    attribute type
  7267.         01h boolean (either 00h or 01h)
  7268.         02h number (BYTE, WORD, or DWORD)
  7269.         03h string
  7270.         04h date stamp
  7271.         05h time stamp
  7272.  01h    WORD    EAP flags (see #0955)
  7273.  03h    BYTE    size of reference string (name)
  7274.  04h  N BYTEs    reference string
  7275.  
  7276. Bitfields for EAP flags:
  7277. Bit(s)    Description    (Table 0955)
  7278.  12    unchangeable
  7279.  13    ignore
  7280.  14    unchangeable
  7281.  15    used by COMMAND.COM for code page, but not understood by ATTRIB
  7282.  
  7283. Format of EAV (extended attribute value) list:
  7284. Offset    Size    Description    (Table 0956)
  7285.  00h    WORD    number of EAV structures following
  7286.  02h    var    array of Extended Attribute Value structures (see #0957)
  7287. SeeAlso: #0953
  7288.  
  7289. Format of Extended Attribute Value structures:
  7290. Offset    Size    Description    (Table 0957)
  7291.  00h  4 BYTEs    ???
  7292.  04h    BYTE    size of reference string
  7293.  05h    WORD    size of value
  7294.  07h    var    reference string
  7295.     var    value
  7296. --------O-215702-----------------------------
  7297. INT 21 - OS/2 v1.1+ Family API - DosQFileInfo
  7298.     AX = 5702h
  7299.     BX = file handle
  7300.     CX = size of buffer for information
  7301.     DX = level of information
  7302.     ES:DI -> buffer for information
  7303. Return: CF clear if successful
  7304.     CF set on error
  7305.         AX = error code
  7306. SeeAlso: AX=5702h/BX=FFFFh,AX=5703h"OS/2"
  7307. --------O-215702BXFFFF-----------------------
  7308. INT 21 - OS/2 v1.1+ Compatibility Box Family API - DosQPathInfo
  7309.     AX = 5702h
  7310.     BX = FFFFh
  7311.     CX = size of buffer for information
  7312.     DX = level of information (0002h)
  7313.     DS:SI -> filename
  7314.     ES:DI -> buffer for FAPI path information (see #0958)
  7315. Return: CF clear if successful
  7316.         AL = 00h
  7317.     CF set on error
  7318.         AX = error code
  7319. SeeAlso: AX=5702h"OS/2",AX=5703h/BX=FFFFh
  7320.  
  7321. Format of FAPI path information:
  7322. Offset    Size    Description    (Table 0958)
  7323.  00h 22 BYTEs    ???
  7324.  16h    DWORD    extended attribute size (none present if less than 5)
  7325. --------D-215703-----------------------------
  7326. INT 21 - DOS 4.x only - GET EXTENDED ATTRIBUTE PROPERTIES
  7327.     AX = 5703h
  7328.     BX = file handle
  7329.     CX = size of result buffer or 0000h
  7330.     ES:DI -> result buffer
  7331. Return: CF clear if successful
  7332.         CX = size of returned data
  7333.     CF set on error
  7334.         AX = error code (see #0960)
  7335.     ES:DI -> zero word (DOS 4.0) if CX >= 2 on entry
  7336. Desc:    get a list of the extended attributes which are defined for the
  7337.       specified file
  7338. Notes:    if CX=0000h on entry, ES:DI is ignored and no data is actually
  7339.       returned, only the amount of data which is available
  7340.     the default DOS 4 behavior is to return a trivial EAP list consisting
  7341.       of the single word 0000h (no EAP structures) if CX>=0002h on entry
  7342. SeeAlso: AX=5702h,AX=5704h,AH=6Eh,INT 2F/AX=112Dh
  7343. --------O-215703-----------------------------
  7344. INT 21 - OS/2 v1.1+ Family API - DosSetFileInfo
  7345.     AX = 5703h
  7346.     BX = file handle
  7347.     CX = size of information buffer
  7348.     DX = level of information
  7349.     ES:DI -> information buffer
  7350. Return: CF clear if successful
  7351.     CF set on error
  7352.         AX = error code
  7353. SeeAlso: AX=5702h"OS/2",AX=5703h/BX=FFFFh
  7354. --------O-215703BXFFFF-----------------------
  7355. INT 21 - OS/2 v1.1+ Family API - DosSetPathInfo
  7356.     AX = 5703h
  7357.     BX = FFFFh
  7358.     CX = size of information buffer
  7359.     DX = level of information
  7360.     DS:SI -> filename
  7361.     ES:DI -> information buffer
  7362. Return: CF clear if successful
  7363.     CF set on error
  7364.         AX = error code
  7365. SeeAlso: AX=5702h/BX=FFFFh,AX=5703h"OS/2"
  7366. --------D-215704-----------------------------
  7367. INT 21 - DOS 4.x only - SET EXTENDED ATTRIBUTES
  7368.     AX = 5704h
  7369.     BX = file handle
  7370.     ES:DI -> EAV list (see #0956)
  7371. Return: CF clear if successful
  7372.     CF set on error
  7373.         AX = error code (see #0960)
  7374. Note:    the default DOS 4 behavior is to do nothing and return successfully
  7375. SeeAlso: AX=5702h,AX=5703h,INT 2F/AX=112Dh
  7376. --------U-215757BX5757-----------------------
  7377. INT 21 U - IBM Genie - Resident Manager - INSTALLATION CHECK
  7378.     AX = 5757h
  7379.     BX = 5757h
  7380. Return: AX = 0000h if installed
  7381.         BX = ???
  7382.         DX = ???
  7383.         DS:SI -> list of 27 DWORD entry point addresses
  7384. Program: IBM Genie is a set of utility TSRs by Helix Software
  7385. Note:    other functions possible if BX <> 5757h, but details not yet available
  7386. ----------215758-----------------------------
  7387. INT 21 U - Headroom - API
  7388.     AX = 5758h
  7389.     BL = function
  7390.         00h ???
  7391.         01h get Headroom location
  7392.         Return: CF clear if installed
  7393.                 AX = PSP segment of Headroom TSR
  7394.                 BX = paragraphs of memory used by Headroom
  7395.             CF set if not (normal DOS return)
  7396.         Note:    this function is also used as an installation check
  7397.         02h get INT 21 handler
  7398.         Return: CF clear
  7399.             ES:BX -> Headroom's INT 21 handler
  7400.         Note: also sets unknown flag
  7401.         03h launch application???
  7402.         DS:SI -> 233-byte application record
  7403.         Return: ???
  7404.         04h ???
  7405.         ???
  7406.         Return: CF clear
  7407.         05h get swap directory
  7408.         Return: CF clear
  7409.             DX:AX -> ASCIZ swap directory name
  7410.         06h ???
  7411.         DX = ???
  7412.         Return: CF clear
  7413.         07h ???
  7414.         08h ???
  7415.         09h get current application
  7416.         Return: BX = application number
  7417.         0Ah ???
  7418.         DX = application number
  7419.         DS:SI = ???
  7420.         Return: ???
  7421.         0Bh ???
  7422.         0Ch ???
  7423.         DX = application number
  7424.         ???
  7425.         Return: ???
  7426.         0Dh ???
  7427.         DX = application number
  7428.         ???
  7429.         Return: ???
  7430.         0Eh get ???
  7431.         Return: CF clear
  7432.             AX = ???
  7433.         0Fh set ??? flag
  7434.         10h clear ??? flag
  7435.         11h find application by name
  7436.         DS:SI -> ASCIZ application name
  7437.         Return: CF clear
  7438.             AX = application number or FFFFh if not loaded
  7439.         12h ???
  7440.         DX = application number
  7441.         Return: CF clear
  7442.             ???
  7443.         13h ???
  7444.         Return: CF clear
  7445.         14h ???
  7446.         same as function 13h
  7447.         15h set ???
  7448.         DX = ???
  7449.         16h get ???
  7450.         Return: AX = ??? set by function 15h
  7451.         17h get ???
  7452.         Return: BX = ???
  7453.             CX = ??? (may be pointer in BX:CX)
  7454.         18h BUG: branches incorrectly due to fencepost error
  7455. Program: Headroom is a TSR/task switcher by Helix Software
  7456. SeeAlso: AX=4C57h,AX=5757h,INT 2F/AX=5758h
  7457. --------D-2158-------------------------------
  7458. INT 21 - DOS 2.11+ - GET OR SET MEMORY ALLOCATION STRATEGY
  7459.     AH = 58h
  7460.     AL = subfunction
  7461.         00h get allocation strategy
  7462.         Return: AX = current strategy (see #0959)
  7463.         01h set allocation strategy
  7464.         BL = new allocation strategy (see #0959)
  7465.         BH = 00h (DOS 5+)
  7466. Return: CF clear if successful
  7467.     CF set on error
  7468.         AX = error code (01h) (see #0960)
  7469. Notes:    the Set subfunction accepts any value in BL for DOS 3.x and 4.x;
  7470.       2 or greater means last fit
  7471.     the Get subfunction returns the last value set
  7472.     setting an allocation strategy involving high memory does not
  7473.       automatically link in the UMB memory chain; this must be done
  7474.       explicitly with AX=5803h in order to actually allocate high memory
  7475.     a program which changes the allocation strategy should restore it
  7476.       before terminating
  7477.     Toshiba MS-DOS v2.11 supports subfunctions 00h and 01h, as does the
  7478.       TI Professional MS-DOS v2.13
  7479.     DR DOS 3.41 reportedly reverses subfunctions 00h and 01h
  7480. SeeAlso: AH=48h,AH=49h,AH=4Ah,INT 2F/AX=4310h,INT 67/AH=3Fh
  7481.  
  7482. (Table 0959)
  7483. Values for DOS memory allocation strategy:
  7484.  00h low memory first fit
  7485.  01h low memory best fit
  7486.  02h low memory last fit
  7487. ---DOS 5+ ---
  7488.  40h high memory first fit
  7489.  41h high memory best fit
  7490.  42h high memory last fit
  7491.  80h first fit, try high then low memory
  7492.  81h best fit, try high then low memory
  7493.  82h last fit, try high then low memory
  7494. --------D-2158-------------------------------
  7495. INT 21 - DOS 5+ - GET OR SET UMB LINK STATE
  7496.     AH = 58h
  7497.     AL = subfunction
  7498.         02h get UMB link state
  7499.         Return: AL = current link state
  7500.                 00h UMBs not part of DOS memory chain
  7501.                 01h UMBs in DOS memory chain
  7502.         03h set UMB link state
  7503.         BX = new link state
  7504.             0000h remove UMBs from DOS memory chain
  7505.             0001h add UMBs to DOS memory chain
  7506. Return: CF clear if successful
  7507.     CF set on error
  7508.         AX = error code (01h) (see #0960)
  7509. Notes:    a program which changes the UMB link state should restore it before
  7510.       terminating
  7511.     UMBs will only be available if CONFIG.SYS contains the line DOS=UMB,
  7512.       the UMBs have been linked into the memory chain with AX=5803h, and
  7513.       the allocation strategy has been set to include high memory with
  7514.       AX=5801h
  7515. SeeAlso: #0967,#1955 at INT 2F/AX=4310h
  7516. --------v-2158CC-----------------------------
  7517. INT 21 - VIRUS - "1067"/"Headcrash" - INSTALLATION CHECK
  7518.     AX = 58CCh
  7519. Return: CF clear if resident
  7520. SeeAlso: AX=5643h,AX=5252h,AX=58DDh,AX=6303h"VIRUS",AX=6969h
  7521. --------v-2158DD-----------------------------
  7522. INT 21 - VIRUS - "1067"/"Headcrash" - GET ORIGINAL INT 21h VECTOR
  7523.     AX = 58DDh
  7524. Return: CX = code segment of virus
  7525.     ES:BX = old INT 21h vector
  7526. SeeAlso: AX=5252h,AX=58CCh,AX=6969h
  7527. --------D-2159--BX0000-----------------------
  7528. INT 21 - DOS 3.0+ - GET EXTENDED ERROR INFORMATION
  7529.     AH = 59h
  7530.     BX = 0000h
  7531. Return: AX = extended error code (see #0960)
  7532.     BH = error class (see #0962)
  7533.     BL = recommended action (see #0963)
  7534.     CH = error locus (see #0964)
  7535.     ES:DI may be pointer (see #0961, error code list below)
  7536.     CL, DX, SI, BP, and DS destroyed
  7537. Notes:    functions available under DOS 2.x map the true DOS 3.0+ error code into
  7538.       one supported under DOS 2.x
  7539.     you should call this function to retrieve the true error code when an
  7540.       FCB or DOS 2.x call returns an error
  7541.     under DR DOS 5.0, this function does not use any of the DOS-internal
  7542.       stacks and may thus be called at any time
  7543. SeeAlso: AH=59h/BX=0001h,AX=5D0Ah,INT 2F/AX=122Dh
  7544.  
  7545. (Table 0960)
  7546. Values for DOS extended error code:
  7547.  00h (0)   no error
  7548.  01h (1)   function number invalid
  7549.  02h (2)   file not found
  7550.  03h (3)   path not found
  7551.  04h (4)   too many open files (no handles available)
  7552.  05h (5)   access denied
  7553.  06h (6)   invalid handle
  7554.  07h (7)   memory control block destroyed
  7555.  08h (8)   insufficient memory
  7556.  09h (9)   memory block address invalid
  7557.  0Ah (10)  environment invalid (usually >32K in length)
  7558.  0Bh (11)  format invalid
  7559.  0Ch (12)  access code invalid
  7560.  0Dh (13)  data invalid
  7561.  0Eh (14)  reserved
  7562.  0Fh (15)  invalid drive
  7563.  10h (16)  attempted to remove current directory
  7564.  11h (17)  not same device
  7565.  12h (18)  no more files
  7566. ---DOS 3.0+ ---
  7567.  13h (19)  disk write-protected
  7568.  14h (20)  unknown unit
  7569.  15h (21)  drive not ready
  7570.  16h (22)  unknown command
  7571.  17h (23)  data error (CRC)
  7572.  18h (24)  bad request structure length
  7573.  19h (25)  seek error
  7574.  1Ah (26)  unknown media type (non-DOS disk)
  7575.  1Bh (27)  sector not found
  7576.  1Ch (28)  printer out of paper
  7577.  1Dh (29)  write fault
  7578.  1Eh (30)  read fault
  7579.  1Fh (31)  general failure
  7580.  20h (32)  sharing violation
  7581.  21h (33)  lock violation
  7582.  22h (34)  disk change invalid (ES:DI -> media ID structure)(see #0961)
  7583.  23h (35)  FCB unavailable
  7584.  24h (36)  sharing buffer overflow
  7585.  25h (37)  (DOS 4.0+) code page mismatch
  7586.  26h (38)  (DOS 4.0+) cannot complete file operation (out of input)
  7587.  27h (39)  (DOS 4.0+) insufficient disk space
  7588.  28h-31h   reserved
  7589.  32h (50)  network request not supported
  7590.  33h (51)  remote computer not listening
  7591.  34h (52)  duplicate name on network
  7592.  35h (53)  network name not found
  7593.  36h (54)  network busy
  7594.  37h (55)  network device no longer exists
  7595.  38h (56)  network BIOS command limit exceeded
  7596.  39h (57)  network adapter hardware error
  7597.  3Ah (58)  incorrect response from network
  7598.  3Bh (59)  unexpected network error
  7599.  3Ch (60)  incompatible remote adapter
  7600.  3Dh (61)  print queue full
  7601.  3Eh (62)  queue not full
  7602.  3Fh (63)  not enough space to print file
  7603.  40h (64)  network name was deleted
  7604.  41h (65)  network: Access denied
  7605.  42h (66)  network device type incorrect
  7606.  43h (67)  network name not found
  7607.  44h (68)  network name limit exceeded
  7608.  45h (69)  network BIOS session limit exceeded
  7609.  46h (70)  temporarily paused
  7610.  47h (71)  network request not accepted
  7611.  48h (72)  network print/disk redirection paused
  7612.  49h (73)  network software not installed
  7613.         (LANtastic) invalid network version
  7614.  4Ah (74)  unexpected adapter close
  7615.         (LANtastic) account expired
  7616.  4Bh (75)  (LANtastic) password expired
  7617.  4Ch (76)  (LANtastic) login attempt invalid at this time
  7618.  4Dh (77)  (LANtastic v3+) disk limit exceeded on network node
  7619.  4Eh (78)  (LANtastic v3+) not logged in to network node
  7620.  4Fh (79)  reserved
  7621.  50h (80)  file exists
  7622.  51h (81)  reserved
  7623.  52h (82)  cannot make directory
  7624.  53h (83)  fail on INT 24h
  7625.  54h (84)  (DOS 3.3+) too many redirections
  7626.  55h (85)  (DOS 3.3+) duplicate redirection
  7627.  56h (86)  (DOS 3.3+) invalid password
  7628.  57h (87)  (DOS 3.3+) invalid parameter
  7629.  58h (88)  (DOS 3.3+) network write fault
  7630.  59h (89)  (DOS 4.0+) function not supported on network
  7631.  5Ah (90)  (DOS 4.0+) required system component not installed
  7632.  64h (100) (MSCDEX) unknown error
  7633.  65h (101) (MSCDEX) not ready
  7634.  66h (102) (MSCDEX) EMS memory no longer valid
  7635.  67h (103) (MSCDEX) not High Sierra or ISO-9660 format
  7636.  68h (104) (MSCDEX) door open
  7637. SeeAlso: #0962,#0963,#0964
  7638.  
  7639. Format of media ID structure:
  7640. Offset    Size    Description    (Table 0961)
  7641.  00h 12 BYTEs    ASCIZ volume label of required disk
  7642.  0Ch    DWORD    serial number (DOS 4.0+)
  7643.  
  7644. (Table 0962)
  7645. Values for DOS Error Class:
  7646.  01h    out of resource (storage space or I/O channels)
  7647.  02h    temporary situation (file or record lock)
  7648.  03h    authorization (denied access)
  7649.  04h    internal (system software bug)
  7650.  05h    hardware failure
  7651.  06h    system failure (configuration file missing or incorrect)
  7652.  07h    application program error
  7653.  08h    not found
  7654.  09h    bad format
  7655.  0Ah    locked
  7656.  0Bh    media error
  7657.  0Ch    already exists
  7658.  0Dh    unknown
  7659. SeeAlso: #0960,#0963,#0964
  7660.  
  7661. (Table 0963)
  7662. Values for DOS Suggested Action:
  7663.  01h    retry
  7664.  02h    delayed retry
  7665.  03h    prompt user to reenter input
  7666.  04h    abort after cleanup
  7667.  05h    immediate abort
  7668.  06h    ignore
  7669.  07h    retry after user intervention
  7670. SeeAlso: #0960,#0962,#0964
  7671.  
  7672. (Table 0964)
  7673. Values for DOS Error Locus:
  7674.  01h    unknown or not appropriate
  7675.  02h    block device (disk error)
  7676.  03h    network related
  7677.  04h    serial device (timeout)
  7678.  05h    memory related
  7679. SeeAlso: #0960,#0962,#0963
  7680. --------D-2159--BX0001-----------------------
  7681. INT 21 - European MS-DOS 4.0 - GET HARD ERROR INFORMATION
  7682.     AH = 59h
  7683.     BX = 0001h
  7684. Return: ES:DI -> hard error information packet (see #0965) for most recent
  7685.         hard (critical) error
  7686. SeeAlso: AH=59h/BX=0000h,AH=95h,INT 24
  7687.  
  7688. Format of European MS-DOS 4.0 hard error information packet:
  7689. Offset    Size    Description    (Table 0965)
  7690.  00h    WORD    contents of AX at system entry
  7691.  02h    WORD    Process ID which encountered error
  7692.  04h    WORD    contents of AX at time of error
  7693.  06h    BYTE    error type
  7694.         00h physical I/O error
  7695.         01h disk change request
  7696.         02h file sharing violation
  7697.         03h FCB problem
  7698.         04h file locking violation
  7699.         05h bad FAT
  7700.         06h network detected error
  7701.  07h    BYTE    INT 24 error code
  7702.  08h    WORD    extended error code (see #0960)
  7703.  0Ah    DWORD    pointer to associated device
  7704. --------D-215A-------------------------------
  7705. INT 21 - DOS 3.0+ - CREATE TEMPORARY FILE
  7706.     AH = 5Ah
  7707.     CX = file attribute (see #0717 at AX=4301h)
  7708.     DS:DX -> ASCIZ path ending with a '\' + 13 zero bytes to receive the
  7709.         generated filename
  7710. Return: CF clear if successful
  7711.         AX = file handle opened for read/write in compatibility mode
  7712.         DS:DX pathname extended with generated name for temporary file
  7713.     CF set on error
  7714.         AX = error code (03h,04h,05h) (see #0960)
  7715. Desc:    creates a file with a unique name which must be explicitly deleted
  7716. BUGS:    COMPAQ DOS 3.31 hangs if the pathname is at XXXXh:0000h; it apparently
  7717.       wraps around to the end of the segment
  7718.     MS-DOS 5.00 revisions A and B and PC-DOS 5.00 revision A reportedly
  7719.       hang the system if the specified path is the root directory and the
  7720.       root directory is full (no free directory entries)
  7721.     Mark Incley <mincley@krisalis.demon.co.uk> reports that this function
  7722.       hangs in DOS 6.2x if the name includes two consecutive path
  7723.       separators (e.g. C:\\ )
  7724. Note:    under the FlashTek X-32 DOS extender, the path pointer is in DS:EDX
  7725. SeeAlso: AH=3Ch,AH=5Bh
  7726. --------D-215B-------------------------------
  7727. INT 21 - DOS 3.0+ - CREATE NEW FILE
  7728.     AH = 5Bh
  7729.     CX = file attribute (see #0717 at AX=4301h)
  7730.     DS:DX -> ASCIZ filename
  7731. Return: CF clear if successful
  7732.         AX = file handle opened for read/write in compatibility mode
  7733.     CF set on error
  7734.         AX = error code (03h,04h,05h,50h) (see #0960)
  7735. Notes:    unlike AH=3Ch, this function will fail if the specified file exists
  7736.       rather than truncating it; this permits its use in creating semaphore
  7737.       files because it is an atomic "test and set" operation
  7738.     under the FlashTek X-32 DOS extender, the filename pointer is in DS:EDX
  7739. SeeAlso: AH=3Ch,AH=5Ah
  7740. --------D-215C-------------------------------
  7741. INT 21 - DOS 3.0+ - "FLOCK" - RECORD LOCKING
  7742.     AH = 5Ch
  7743.     AL = subfunction
  7744.         00h lock region of file
  7745.         01h unlock region of file
  7746.     BX = file handle
  7747.     CX:DX = start offset of region within file
  7748.     SI:DI = length of region in bytes
  7749. Return: CF clear if successful
  7750.     CF set on error
  7751.         AX = error code (01h,06h,21h,24h) (see #0960)
  7752. Notes:    error returned unless SHARE or network installed
  7753.     an unlock call must specify the same region as some prior lock call
  7754.     locked regions become entirely inaccessible to other processes
  7755.     duplicate handles created with AH=45h or AH=46h inherit locks, but
  7756.       handles inherited by child processes (see AH=4Bh) do not
  7757.     under DR DOS 3.41 and 5.0, if a process opens a file without the no-
  7758.       inherit flag and then starts a child, any locks set by the parent
  7759.       are ignored, and the child will only get an error if it tries to
  7760.       lock an area previously locked by the parent process
  7761. SeeAlso: AX=440Bh,AH=BCh,AH=BEh,INT 2F/AX=110Ah,INT 2F/AX=110Bh
  7762. --------D-215D00-----------------------------
  7763. INT 21 U - DOS 3.1+ internal - SERVER FUNCTION CALL
  7764.     AX = 5D00h
  7765.     DS:DX -> DOS parameter list (see #0966)
  7766.     DPL contains all register values for a call to INT 21h
  7767. Return: as appropriate for function being called
  7768. Notes:    does not check AH.  Out of range values will crash the system
  7769.     executes using specified computer ID and process ID
  7770.     sharing delay loops skipped
  7771.     a special sharing mode is enabled to handle FCBs opened across network
  7772.     wildcards are enabled for DELETE (AH=41h) and RENAME (AH=56h) under
  7773.       MS-DOS; under DR DOS 3.41, wildcards corrupt the filesystem; and
  7774.       under DR DOS 5.0-6.0, the call returns error code 03h due to improper
  7775.       support for the server function call (see below)
  7776.     an extra file attribute parameter is enabled for OPEN (AH=3Dh),
  7777.       DELETE (AH=41h), and RENAME (AH=56h)
  7778.     functions which take filenames require canonical names (as returned
  7779.       by AH=60h); this is apparently to prevent multi-hop file forwarding
  7780. BUGS:    the OS/2 2.0 DOS Boot Session incorrectly maps DOS drive letters,
  7781.       seemingly ignoring HPFS drives
  7782.     DR DOS 5.0-6.0 merely recursively call INT 21 after loading the
  7783.       registers from the DPL, leading to problems for peer-to-peer
  7784.       networks
  7785. SeeAlso: AH=3Dh,AH=41h,AH=56h,AH=60h
  7786.  
  7787. Format of DOS parameter list:
  7788. Offset    Size    Description    (Table 0966)
  7789.  00h    WORD    AX
  7790.  02h    WORD    BX
  7791.  04h    WORD    CX
  7792.  06h    WORD    DX
  7793.  08h    WORD    SI
  7794.  0Ah    WORD    DI
  7795.  0Ch    WORD    DS
  7796.  0Eh    WORD    ES
  7797.  10h    WORD    reserved (0)
  7798.  12h    WORD    computer ID (0 = current system)
  7799.  14h    WORD    process ID (PSP segment on specified computer)
  7800. Note:    under Windows Enhanced mode, the computer ID is normally the virtual
  7801.       machine ID (see INT 2F/AX=1683h), though this can reportedly be
  7802.       changed by setting UniqueDOSPSP= in SYSTEM.INI
  7803. --------D-215D01-----------------------------
  7804. INT 21 U - DOS 3.1+ internal - COMMIT ALL FILES FOR SPECIFIED COMPUTER/PROCESS
  7805.     AX = 5D01h
  7806.     DS:DX -> DOS parameter list (see #0966), only computer ID and
  7807.           process ID fields used
  7808. Return: CF set on error
  7809.         AX = error code (see #0960)
  7810.     CF clear if successful
  7811. Notes:    flushes buffers and updates directory entries for each file which has
  7812.       been written to; if remote file, calls INT 2F/AX=1107h
  7813.     the computer ID and process ID are stored but ignored under DOS 3.3
  7814.     not supported by DR DOS 3.41 and 5.0; returns error code 01h
  7815. SeeAlso: AH=0Dh,AH=68h,INT 2F/AX=1107h
  7816. --------D-215D02-----------------------------
  7817. INT 21 U - DOS 3.1+ internal - SHARE.EXE - CLOSE FILE BY NAME
  7818.     AX = 5D02h
  7819.     DS:DX -> DOS parameter list (see #0966), only fields DX, DS,
  7820.           computer ID, and process ID used
  7821.     DPL's DS:DX -> ASCIZ name of file to close
  7822. Return: CF set on error
  7823.         AX = error code (see #0960)
  7824.     CF clear if successful
  7825. Notes:    error unless SHARE is loaded (calls [SysFileTable-28h])
  7826.       (see #0923 at AH=52h)
  7827.     name must be canonical fully-qualified, such as returned by AH=60h
  7828.     not supported by DR DOS 3.41 and 5.0; returns error code 01h
  7829.     not supported by Novell DOS 7
  7830. SeeAlso: AX=5D03h,AX=5D04h,AH=3Eh,AH=60h
  7831. --------D-215D03-----------------------------
  7832. INT 21 U - DOS 3.1+ internal - SHARE.EXE - CLOSE ALL FILES FOR GIVEN COMPUTER
  7833.     AX = 5D03h
  7834.     DS:DX -> DOS parameter list (see #0966), only computer ID used
  7835. Return: CF set on error
  7836.         AX = error code (see #0960)
  7837.     CF clear if successful
  7838. Notes:    error unless SHARE is loaded (calls [SysFileTable-30h])
  7839.       (see #0923 at AH=52h)
  7840.     not supported by DR DOS 3.41 and 5.0; returns error code 01h
  7841.     not supported by Novell DOS 7
  7842. SeeAlso: AX=5D02h,AX=5D04h
  7843. --------D-215D04-----------------------------
  7844. INT 21 U - DOS 3.1+ internal - SHARE.EXE - CLOSE ALL FILES FOR GIVEN PROCESS
  7845.     AX = 5D04h
  7846.     DS:DX -> DOS parameter list (see #0966), only computer ID and
  7847.           process ID fields used
  7848. Return: CF set on error
  7849.         AX = error code (see #0960)
  7850.     CF clear if successful
  7851. Notes:    error unless SHARE is loaded (calls [SysFileTable-2Ch])
  7852.        (see #0923 at AH=52h)
  7853.     not supported by DR DOS 3.41 and 5.0; returns error code 01h
  7854.     not supported by Novell DOS 7
  7855. SeeAlso: AX=5D02h,AX=5D03h,INT 2F/AX=111Dh
  7856. --------D-215D05-----------------------------
  7857. INT 21 U - DOS 3.1+ internal - SHARE.EXE - GET OPEN FILE LIST ENTRY
  7858.     AX = 5D05h
  7859.     DS:DX -> DOS parameter list (see #0966)
  7860.     DPL's BX = index of sharing record (see #0924 at AH=52h)
  7861.     DPL's CX = index of SFT in sharing record's SFT list
  7862. Return: CF clear if successful
  7863.         ES:DI -> ASCIZ filename
  7864.         BX = network machine number of SFT's owner
  7865.         CX = number of locks held by SFT's owner
  7866.     CF set if either index out of range
  7867.         AX = 0012h (no more files)
  7868. Notes:    error unless SHARE is loaded (calls [SysFileTable-18h])
  7869.       (see #0923 at AH=52h)
  7870.     names are always canonical fully-qualified, such as returned by AH=60h
  7871.     not supported by DR DOS 3.41 and 5.0 and Novell DOS 7, but does not
  7872.       return an error, instead destroying AX
  7873. SeeAlso: AH=5Ch,AH=60h
  7874. --------D-215D06-----------------------------
  7875. INT 21 U - DOS 3.0+ internal - GET ADDRESS OF DOS SWAPPABLE DATA AREA
  7876.     AX = 5D06h
  7877. Return: CF set on error
  7878.        AX = error code (see #0960)
  7879.     CF clear if successful
  7880.         DS:SI -> nonreentrant data area (includes all three DOS stacks)
  7881.         (critical error flag is first byte) (see #0967)
  7882.         CX = size in bytes of area which must be swapped while in DOS
  7883.         DX = size in bytes of area which must always be swapped
  7884. Notes:    the Critical Error flag is used in conjunction with the InDOS flag
  7885.       (see AH=34h) to determine when it is safe to enter DOS from a TSR
  7886.     setting CritErr flag allows use of functions 50h/51h from INT 28h under
  7887.       DOS 2.x by forcing use of correct stack
  7888.     swapping the data area allows reentering DOS unless DOS is in a
  7889.       critical section delimited by INT 2A/AH=80h and INT 2A/AH=81h,82h
  7890.     under DOS 4.0, AX=5D0Bh should be used instead of this function
  7891.     SHARE and other DOS utilities consult the byte at offset 04h in the
  7892.       DOS data segment (see INT 2F/AX=1203h) to determine the SDA format
  7893.       in use: 00h = DOS 3.x, 01h = DOS 4.0-6.0, other = error.
  7894.     DR DOS 3.41+ supports this function, but the SDA format beyond the
  7895.       first 18h bytes is completely different from MS-DOS
  7896. SeeAlso: AX=5D0Bh,INT 2A/AH=80h,INT 2A/AH=81h,INT 2A/AH=82h
  7897.  
  7898. Format of DOS 3.10-3.30 Swappable Data Area:
  7899. Offset    Size    Description    (Table 0967)
  7900.  -34    BYTE    (DOS 3.10+) printer echo flag (00h off, FFh active)
  7901.  -31    BYTE    (DOS 3.30) current switch character
  7902.  -30    BYTE    current memory allocation strategy (see AH=58h)
  7903.  -28    BYTE    (DOS 3.30) incremented on each INT 21/AX=5E01h call
  7904.  -27 16 BYTEs    (DOS 3.30) machine name set by INT 21/AX=5E01h
  7905.  -11  5 WORDs    zero-terminated list of offsets which need to be patched to
  7906.           enable critical-section calls (see INT 2A/AH=80h)
  7907.  -1    BYTE    unused padding
  7908. ---start of actual SDA---
  7909.  00h    BYTE    critical error flag ("ErrorMode")
  7910.  01h    BYTE    InDOS flag (count of active INT 21 calls)
  7911.  02h    BYTE    drive on which current critical error occurred, or FFh
  7912.         (DR DOS sets to drive number during INT 24, 00h otherwise)
  7913.  03h    BYTE    locus of last error
  7914.  04h    WORD    extended error code of last error
  7915.  06h    BYTE    suggested action for last error
  7916.  07h    BYTE    class of last error
  7917.  08h    DWORD    ES:DI pointer for last error
  7918.  0Ch    DWORD    current DTA (Disk Transfer Address)
  7919.         note: may point into SDA during the DOS EXEC function
  7920.           (see AH=4Bh), so programs which swap the SDA must be
  7921.           prepared to move the DTA to a private buffer if they
  7922.           might be invoked during an EXEC
  7923.  10h    WORD    current PSP
  7924.  12h    WORD    stores SP across an INT 23
  7925.  14h    WORD    return code from last process termination (zerod after reading
  7926.           with AH=4Dh)
  7927.  16h    BYTE    current drive
  7928.  17h    BYTE    extended break flag
  7929. ---remainder need only be swapped if in DOS---
  7930.  18h    WORD    value of AX on call to INT 21
  7931.  1Ah    WORD    PSP segment for sharing/network
  7932.  1Ch    WORD    network machine number for sharing/network (0000h = us)
  7933.  1Eh    WORD    first usable memory block found when allocating memory
  7934.  20h    WORD    best usable memory block found when allocating memory
  7935.  22h    WORD    last usable memory block found when allocating memory
  7936.  24h    WORD    memory size in paragraphs (used only during initialization)
  7937.  26h    WORD    last entry checked during directory search
  7938.  28h    BYTE    flag: INT 24 returned Fail
  7939.  29h    BYTE    flags: allowable INT 24 actions (passed to INT 24 in AH)
  7940.  2Ah    BYTE    directory flag (00h directory, 01h file)
  7941.  2Bh    BYTE    flag: FFh if Ctrl-Break termination, 00h otherwise
  7942.  2Ch    BYTE    flag: allow embedded blanks in FCB
  7943.  2Dh    BYTE    padding (unused)
  7944.  2Eh    BYTE    day of month
  7945.  2Fh    BYTE    month
  7946.  30h    WORD    year - 1980
  7947.  32h    WORD    number of days since 1-1-1980
  7948.  34h    BYTE    day of week (0 = Sunday)
  7949.  35h    BYTE    flag: console swapped during read from device
  7950.  36h    BYTE    flag: safe to call INT 28 if nonzero
  7951.  37h    BYTE    flag: if nonzero, INT 24 Abort turned into INT 24 Fail
  7952.         (set only during process termination)
  7953.  38h 26 BYTEs    device driver request header (see #1845 at INT 2F/AX=0802h)
  7954.  52h    DWORD    pointer to device driver entry point (used in calling driver)
  7955.  56h 22 BYTEs    device driver request header for I/O calls
  7956.  6Ch 14 BYTEs    device driver request header for disk status check
  7957.  7Ah    DWORD    pointer to device I/O buffer???
  7958.  7Eh    WORD    ???
  7959.  80h    WORD    ???
  7960.  82h    BYTE    type of PSP copy (00h=simple for INT 21/AH=26h, FFh=make child)
  7961.  83h    BYTE    padding (unused)
  7962.  84h  3 BYTEs    24-bit user number (see AH=30h)
  7963.  87h    BYTE    OEM number (see #0693 at AH=30h)
  7964.  88h    WORD    offset to error code conversion table for INT 25/INT 26
  7965.  8Ah  6 BYTEs    CLOCK$ transfer record (see #0968)
  7966.  90h    BYTE    device I/O buffer for single-byte I/O functions
  7967.  91h    BYTE    padding??? (unused)
  7968.  92h 128 BYTEs    buffer for filename
  7969. 112h 128 BYTEs    buffer for filename
  7970. 192h 21 BYTEs    findfirst/findnext search data block (see #0913 at AH=4Eh)
  7971. 1A7h 32 BYTEs    directory entry for found file (see #0654 at AH=11h)
  7972. 1C7h 81 BYTEs    copy of current directory structure for drive being accessed
  7973. 218h 11 BYTEs    FCB-format filename for device name comparison
  7974. 223h    BYTE    terminating NUL for above filename
  7975. 224h 11 BYTEs    wildcard destination specification for rename (FCB format)
  7976. 22Fh    BYTE    terminating NUL for above spec
  7977. 230h    BYTE    ???
  7978. 231h    WORD    destination file/directory starting sector
  7979. 233h  5 BYTEs    ???
  7980. 238h    BYTE    extended FCB file attribute
  7981. 239h    BYTE    type of FCB (00h regular, FFh extended)
  7982. 23Ah    BYTE    directory search attributes
  7983. 23Bh    BYTE    file open/access mode
  7984. 23Ch    BYTE    file found/delete flag
  7985.         bit 0: file found
  7986.         bit 4: file deleted
  7987. 23Dh    BYTE    flag: device name found on rename, or file not found
  7988. 23Eh    BYTE    splice flag (file name and directory name together)
  7989. 23Fh    BYTE    flag indicating how DOS function was invoked
  7990.         (00h = direct INT 20/INT 21, FFh = server call AX=5D00h)
  7991. 240h    BYTE    sector position within cluster
  7992. 241h    BYTE    flag: translate sector/cluster (00h no, 01h yes)
  7993. 242h    BYTE    flag: 00h if read, 01h if write
  7994. 243h    BYTE    current working drive number
  7995. 244h    BYTE    cluster factor
  7996. 245h    BYTE    flag: cluster split mode
  7997. 246h    BYTE    line edit (AH=0Ah) insert mode flag (nonzero = on)
  7998. 247h    BYTE    canonicalized filename referred to existing file/dir if FFh
  7999. 248h    BYTE    volume ID flag
  8000. 249h    BYTE    type of process termination (00h-03h) (see AH=4Dh)
  8001. 24Ah    BYTE    file create flag (00h = no, search only)
  8002. 24Bh    BYTE    value with which to replace first byte of deleted file's name
  8003.           (normally E5h, but 00h as described under INT 21/AH=13h)
  8004. 24Ch    DWORD    pointer to Drive Parameter Block for critical error invocation
  8005.         temp: used during process termination
  8006. 250h    DWORD    pointer to stack frame containing user registers on INT 21
  8007. 254h    WORD    stores SP across INT 24
  8008. 256h    DWORD    pointer to DOS Drive Parameter Block for ???
  8009. 25Ah    WORD    saving partial cluster number
  8010. 25Ch    WORD    temp: sector of work current cluster
  8011. 25Eh    WORD    high part of cluster number (only low byte referenced)
  8012. 260h    WORD    ??? temp
  8013. 262h    BYTE    Media ID byte returned by AH=1Bh,1Ch
  8014. 263h    BYTE    padding (unused)
  8015. 264h    DWORD    pointer to device header when filename is character device
  8016. 268h    DWORD    pointer to current SFT
  8017. 26Ch    DWORD    pointer to current directory structure for drive being accessed
  8018. 270h    DWORD    pointer to caller's FCB
  8019. 274h    WORD    number of SFT to which file being opened will refer
  8020. 276h    WORD    temporary storage for file handle
  8021. 278h    DWORD    pointer to a JFT entry in process handle table
  8022.           (see #0677 at AH=26h)
  8023. 27Ch    WORD    offset in DOS DS of first filename argument
  8024. 27Eh    WORD    offset in DOS DS of second filename argument
  8025. 280h    WORD    offset of last component in pathname or FFFFh
  8026. 282h    WORD    offset of transfer address to add
  8027. 284h    WORD    last relative cluster within file being accessed
  8028. 286h    WORD    temp: absolute cluster number being accessed
  8029. 288h    WORD    directory sector number
  8030. 28Ah    WORD    ??? current cluster number
  8031. 28Ch    WORD    current relative sector number within file
  8032. 28Eh    WORD    current sector number
  8033. 290h    WORD    current byte offset within sector
  8034. 292h    DWORD    current offset in file
  8035. 296h    DWORD    temp: file byte count
  8036. 29Ah    WORD    temp: file byte count
  8037. 29Ch    WORD    free file cluster entry
  8038. 29Eh    WORD    last file cluster entry
  8039. 2A0h    WORD    next file cluster number
  8040. 2A2h    DWORD    number of bytes appended to file
  8041. 2A6h    DWORD    pointer to current work disk buffer
  8042. 2AAh    DWORD    pointer to working SFT
  8043. 2AEh    WORD    used by INT 21 dispatcher to store caller's BX
  8044. 2B0h    WORD    used by INT 21 dispatcher to store caller's DS
  8045. 2B2h    WORD    temporary storage while saving/restoring caller's registers
  8046. 2B4h    DWORD    pointer to prev call frame (offset 250h) if INT 21 reentered
  8047.         also switched to for duration of INT 24
  8048. 2B8h 21 BYTEs    FindFirst search data for source file(s) of a rename operation
  8049.         (see #0913 at AH=4Eh)
  8050. 2CDh 32 BYTEs    directory entry for file being renamed (see #0654 at AH=11h)
  8051. 2EDh 331 BYTEs    critical error stack
  8052.    403h     35 BYTEs scratch SFT
  8053. 438h 384 BYTEs    disk stack (functions greater than 0Ch, INT 25,INT 26)
  8054. 5B8h 384 BYTEs    character I/O stack (functions 01h through 0Ch)
  8055. ---DOS 3.2,3.3x only---
  8056. 738h    BYTE    device driver lookahead flag (usually printer) (see AH=64h)
  8057. 739h    BYTE    volume change flag
  8058. 73Ah    BYTE    flag: virtual open
  8059. 73Bh    BYTE    ???
  8060. SeeAlso: #0970
  8061.  
  8062. Format of CLOCK$ transfer record:
  8063. Offset    Size    Description    (Table 0968)
  8064.  00h    WORD    number of days since 1-Jan-1980
  8065.  02h    BYTE    minutes
  8066.  03h    BYTE    hours
  8067.  04h    BYTE    hundredths of second
  8068.  05h    BYTE    seconds
  8069. --------D-215D07-----------------------------
  8070. INT 21 U - DOS 3.1+ network - GET REDIRECTED PRINTER MODE
  8071.     AX = 5D07h
  8072. Return: DL = mode
  8073.         00h redirected output is combined
  8074.         01h redirected output in separate print jobs
  8075. SeeAlso: AX=5D08h,AX=5D09h,INT 2F/AX=1125h
  8076. --------D-215D08-----------------------------
  8077. INT 21 U - DOS 3.1+ network - SET REDIRECTED PRINTER MODE
  8078.     AX = 5D08h
  8079.     DL = mode
  8080.         00h redirected output is combined
  8081.         01h redirected output placed in separate jobs, start new print job
  8082.         now
  8083. SeeAlso: AX=5D07h,AX=5D09h,INT 2F/AX=1125h
  8084. --------D-215D09-----------------------------
  8085. INT 21 U - DOS 3.1+ network - FLUSH REDIRECTED PRINTER OUTPUT
  8086.     AX = 5D09h
  8087. Notes:    forces redirected printer output to be printed, and starts a new print
  8088.       job
  8089.     this function is also supported by 10Net, which calls it Terminate All
  8090.       Spool Jobs, and does not flush if in "combine" mode
  8091. SeeAlso: AX=5D07h,AX=5D08h,INT 2F/AX=1125h
  8092. --------D-215D0A-----------------------------
  8093. INT 21 - DOS 3.1+ - SET EXTENDED ERROR INFORMATION
  8094.     AX = 5D0Ah
  8095.     DS:DX -> 11-word DOS parameter list (see #0966)
  8096. Return: nothing.  next call to AH=59h will return values from fields AX,BX,CX,
  8097.       DX,DI, and ES in corresponding registers
  8098. Notes:    documented for DOS 5+, but undocumented in earlier versions
  8099.     the MS-DOS Programmer's Reference incorrectly states that this call was
  8100.       introduced in DOS 4, and fails to mention that the ERROR structure
  8101.       passed to this function is a DOS parameter list.
  8102. BUGS:    DR DOS 3.41 and 5.0 read the value for ES from the DS field of the
  8103.       DPL; fortunately, MS-DOS ignores the DS field, allowing a generic
  8104.       routine which sets both DS and ES fields to the same value
  8105.     Novell DOS 7 does not save the pointer, which is always reported as
  8106.       0000h:0000h by AH=59h
  8107. SeeAlso: AH=59h/BX=0000h
  8108. --------D-215D0B-----------------------------
  8109. INT 21 OU - DOS 4.x only internal - GET DOS SWAPPABLE DATA AREAS
  8110.     AX = 5D0Bh
  8111. Return: CF set on error
  8112.         AX = error code (see #0960)
  8113.     CF clear if successful
  8114.         DS:SI -> swappable data area list (see #0969)
  8115. Notes:    copying and restoring the swappable data areas allows DOS to be
  8116.       reentered unless it is in a critical section delimited by calls to
  8117.       INT 2A/AH=80h and INT 2A/AH=81h,82h
  8118.     SHARE and other DOS utilities consult the byte at offset 04h in the
  8119.       DOS data segment (see INT 2F/AX=1203h) to determine the SDA format
  8120.       in use: 00h = DOS 3.x, 01h = DOS 4.0-6.0, other = error.
  8121.     DOS 5+ use the SDA format listed below, but revert back to the DOS 3.x
  8122.       call for finding the SDA (see #0967)
  8123. SeeAlso: AX=5D06h,INT 2A/AH=80h,INT 2A/AH=81h,INT 2A/AH=82h,INT 2F/AX=1203h
  8124.  
  8125. Format of DOS 4.x swappable data area list:
  8126. Offset    Size    Description    (Table 0969)
  8127.  00h    WORD    count of data areas
  8128.  02h  N BYTEs    "count" copies of data area record
  8129.         Offset    Size    Description
  8130.          00h    DWORD    address
  8131.          04h    WORD    length and type
  8132.                 bit 15 set if swap always, clear if swap in DOS
  8133.                 bits 14-0: length in bytes
  8134. SeeAlso: #0970
  8135.  
  8136. Format of DOS 4.0-6.0 swappable data area:
  8137. Offset    Size    Description    (Table 0970)
  8138.  -34    BYTE    printer echo flag (00h off, FFh active)
  8139.  -31    BYTE    current switch character (ignored by DOS 5+)
  8140.  -30    BYTE    current memory allocation strategy (see AH=58h)
  8141.  -28    BYTE    incremented on each INT 21/AX=5E01h call
  8142.  -27 16 BYTEs    machine name set by INT 21/AX=5E01h
  8143.  -11  5 WORDs    zero-terminated list of offsets which need to be patched to
  8144.           enable critical-section calls (see INT 2A/AH=80h)
  8145.         (all offsets are 0D0Ch, but this list is still present for
  8146.           DOS 3.x compatibility)
  8147.  -1    BYTE    unused padding
  8148. ---start of actual SDA---
  8149.  00h    BYTE    critical error flag ("ErrorMode")
  8150.  01h    BYTE    InDOS flag (count of active INT 21 calls)
  8151.  02h    BYTE    drive on which current critical error occurred or FFh
  8152.  03h    BYTE    locus of last error
  8153.  04h    WORD    extended error code of last error
  8154.  06h    BYTE    suggested action for last error
  8155.  07h    BYTE    class of last error
  8156.  08h    DWORD    ES:DI pointer for last error
  8157.  0Ch    DWORD    current DTA (Disk Transfer Address)
  8158.         note: may point into SDA during the DOS EXEC function
  8159.           (see AH=4Bh), so programs which swap the SDA must be
  8160.           prepared to move the DTA to a private buffer if they
  8161.           might be invoked during an EXEC
  8162.  10h    WORD    current PSP
  8163.  12h    WORD    stores SP across an INT 23
  8164.  14h    WORD    return code from last process termination (zerod after reading
  8165.           with AH=4Dh)
  8166.  16h    BYTE    current drive
  8167.  17h    BYTE    extended break flag
  8168.  18h    BYTE    flag: code page switching
  8169.  19h    BYTE    flag: copy of previous byte in case of INT 24 Abort
  8170. ---remainder need only be swapped if in DOS---
  8171.  1Ah    WORD    value of AX on call to INT 21
  8172.  1Ch    WORD    PSP segment for sharing/network
  8173.  1Eh    WORD    network machine number for sharing/network (0000h = us)
  8174.  20h    WORD    first usable memory block found when allocating memory
  8175.  22h    WORD    best usable memory block found when allocating memory
  8176.  24h    WORD    last usable memory block found when allocating memory
  8177.  26h    WORD    memory size in paragraphs (used only during initialization)
  8178.  28h    WORD    last entry checked during directory search
  8179.  2Ah    BYTE    flag: nonzero if INT 24 Fail
  8180.  2Bh    BYTE    flags: allowable INT 24 responses (passed to INT 24 in AH)
  8181.  2Ch    BYTE    flag: do not set directory if nonzero
  8182.  2Dh    BYTE    flag: program aborted by ^C
  8183.  2Eh    BYTE    flag: allow embedded blanks in FCB
  8184.         may also allow use of "*" wildcard in FCBs
  8185.  2Fh    BYTE    padding (unused)
  8186.  30h    BYTE    day of month
  8187.  31h    BYTE    month
  8188.  32h    WORD    year - 1980
  8189.  34h    WORD    number of days since 1-1-1980
  8190.  36h    BYTE    day of week (0 = Sunday)
  8191.  37h    BYTE    flag: console swapped during read from device
  8192.  38h    BYTE    flag: safe to call INT 28 if nonzero
  8193.  39h    BYTE    flag: abort currently in progress, turn INT 24 Abort into Fail
  8194.  3Ah 30 BYTEs    device driver request header (see #1845 at INT 2F/AX=0802h) for
  8195.           device calls
  8196.  58h    DWORD    pointer to device driver entry point (used in calling driver)
  8197.  5Ch 22 BYTEs    device driver request header for I/O calls
  8198.  72h 14 BYTEs    device driver request header for disk status check
  8199.  80h    DWORD    pointer to device I/O buffer
  8200.  84h    WORD    ???
  8201.  86h    WORD    ??? (0)
  8202.  88h    BYTE    type of PSP copy (00h=simple for INT 21/AH=26h, FFh=make child)
  8203.  89h    DWORD    start offset of file region to lock/unlock
  8204.  8Dh    DWORD    length of file region to lock/unlock
  8205.  91h    BYTE    padding (unused)
  8206.  92h  3 BYTEs    24-bit user number (see AH=30h)
  8207.  95h    BYTE    OEM number (see #0693 at AH=30h)
  8208.  96h  6 BYTEs    CLOCK$ transfer record (see #0968 at AX=5D06h)
  8209.  9Ch    BYTE    device I/O buffer for single-byte I/O functions
  8210.  9Dh    BYTE    padding???
  8211.  9Eh 128 BYTEs    buffer for filename
  8212. 11Eh 128 BYTEs    buffer for filename
  8213. 19Eh 21 BYTEs    findfirst/findnext search data block (see #0913 at AH=4Eh)
  8214. 1B3h 32 BYTEs    directory entry for found file (see #0693 at AH=11h)
  8215. 1D3h 88 BYTEs    copy of current directory structure for drive being accessed
  8216. 22Bh 11 BYTEs    FCB-format filename for device name comparison
  8217. 236h    BYTE    terminating NUL for above filename
  8218. 237h 11 BYTEs    wildcard destination specification for rename (FCB format)
  8219. 242h    BYTE    terminating NUL for above filespec
  8220. 243h    BYTE    ???
  8221. 244h    WORD    ???
  8222. 246h  5 BYTEs    ???
  8223. 24Bh    BYTE    extended FCB file attributes
  8224. 24Ch    BYTE    type of FCB (00h regular, FFh extended)
  8225. 24Dh    BYTE    directory search attributes
  8226. 24Eh    BYTE    file open/access mode
  8227. 24Fh    BYTE    ??? flag bits
  8228.         reportedly 00h when deleting a file under MSDOS 5.0
  8229. 250h    BYTE    flag: device name found on rename, or file not found
  8230. 251h    BYTE    splice flag??? (file name and directory name together)
  8231. 252h    BYTE    flag indicating how DOS function was invoked
  8232.         (00h = direct INT 20/INT 21, FFh = server call AX=5D00h)
  8233. 253h    BYTE    sector position within cluster
  8234. 254h    BYTE    ??? (flag: translate sector/cluster)
  8235. 255h    BYTE    ??? (flag: 00h if read, 01h if write)
  8236. 256h    BYTE    current working drive number
  8237. 257h    BYTE    cluster factor
  8238. 258h    BYTE    ???
  8239. 259h    BYTE    line edit (AH=0Ah) insert mode flag (nonzero = on)
  8240. 25Ah    BYTE    canonicalized filename referred to existing file/dir if FFh
  8241. 25Bh    BYTE    volume ID flag
  8242. 25Ch    BYTE    type of process termination (00h-03h) (see AH=4Dh)
  8243. 25Dh    BYTE    ???
  8244. 25Eh    BYTE    ??? file create flag (00h = no, search only)
  8245. 25Fh    BYTE    ??? (value for deleted file's first byte)
  8246. 260h    DWORD    pointer to Drive Parameter Block for critical error invocation
  8247. 264h    DWORD    pointer to stack frame containing user registers on INT 21
  8248. 268h    WORD    stores SP across INT 24
  8249. 26Ah    DWORD    pointer to DOS Drive Parameter Block for ???
  8250. 26Eh    WORD    segment of disk buffer
  8251. 270h    WORD    ??? (saving partial cluster number)
  8252. 272h    WORD    ??? (temp: sector of work current cluster)
  8253. 274h    WORD    ??? (high part of cluster number)
  8254. 276h    WORD    ??? (temp)
  8255. 278h    BYTE    Media ID byte returned by AH=1Bh,1Ch
  8256. 279h    BYTE    ??? (doesn't seem to be referenced)
  8257. 27Ah    DWORD    pointer to device header if filename is character device
  8258. 27Eh    DWORD    pointer to current SFT
  8259. 282h    DWORD    pointer to current directory structure for drive being accessed
  8260. 286h    DWORD    pointer to caller's FCB
  8261. 28Ah    WORD    SFT index to which file being opened will refer
  8262. 28Ch    WORD    temporary storage for file handle
  8263. 28Eh    DWORD    pointer to a JFT entry in process handle table
  8264.           (see #0677 at AH=26h)
  8265. 292h    WORD    offset in DOS DS of first filename argument
  8266. 294h    WORD    offset in DOS DS of second filename argument
  8267. 296h    WORD    ??? (offset of last component in pathname or FFFFh)
  8268. 298h    WORD    offset of transfer address to add
  8269. 29Ah    WORD    last relative cluster within file being accessed
  8270. 29Ch    WORD    temp: absolute cluster number being accessed
  8271. 29Eh    WORD    directory sector number
  8272. 2A0h    WORD    ???
  8273. 2A2h    WORD    ??? directory cluster number
  8274. 2A4h    DWORD    current relative sector number within file
  8275. 2A8h    DWORD    ??? (current sector number)
  8276. 2ACh    WORD    ??? (current byte offset within sector)
  8277. 2AEh    DWORD    current offset in file
  8278. 2B2h    WORD    ???
  8279. 2B4h    WORD    bytes in partial sector
  8280. 2B6h    WORD    number of sectors
  8281. 2B8h    WORD    ??? (free file cluster entry)
  8282. 2BAh    WORD    ??? (last file cluster entry)
  8283. 2BCh    WORD    ??? (next file cluster number)
  8284. 2BEh    DWORD    number of bytes appended to file
  8285. 2C2h    DWORD    pointer to current work disk buffer
  8286. 2C6h    DWORD    pointer to working SFT
  8287. 2CAh    WORD    used by INT 21 dispatcher to store caller's BX
  8288. 2CCh    WORD    used by INT 21 dispatcher to store caller's DS
  8289. 2CEh    WORD    temporary storage while saving/restoring caller's registers
  8290. 2D0h    DWORD    pointer to prev call frame (offset 264h) if INT 21 reentered
  8291.         also switched to for duration of INT 24
  8292. 2D4h    WORD    open mode/action for INT 21/AX=6C00h
  8293. 2D6h    BYTE    ??? (set to 00h by INT 21h dispatcher, 02h when a read is
  8294.           performed, and 01h or 03h by INT 21/AX=6C00h)
  8295. 2D7h    WORD    ??? apparently unused
  8296. 2D9h    DWORD    stored ES:DI for AX=6C00h
  8297. 2DDh    WORD    extended file open action code (see #1044 at AX=6C00h)
  8298. 2DFh    WORD    extended file open attributes (see #1043 at AX=6C00h)
  8299. 2E1h    WORD    extended file open file mode (see AX=6C00h)
  8300. 2E3h    DWORD    pointer to filename to open (see AX=6C00h)
  8301. 2E7h    WORD    ??? temp DX storage or 0000h or temp data buffer size from
  8302.           disk buffer
  8303. 2E9h    WORD    ???
  8304. 2EBh    BYTE    ???
  8305. 2ECh    WORD    stores DS during call to [List-of-Lists + 37h]
  8306. 2EEh    WORD    ???
  8307. 2F0h    BYTE    ???
  8308. 2F1h    WORD    ??? bit flags
  8309. 2F3h    DWORD    pointer to user-supplied filename
  8310. 2F7h    DWORD    pointer to ???
  8311. 2FBh    WORD    stores SS during call to [List-of-Lists + 37h]
  8312. 2FDh    WORD    stores SP during call to [List-of-Lists + 37h]
  8313. 2FFh    BYTE    flag, nonzero if stack switched in calling [List-of-Lists+37h]
  8314. 300h 21 BYTEs    FindFirst search data for source file(s) of a rename operation
  8315.         (see #0913 at AH=4Eh)
  8316. 315h 32 BYTEs    directory entry for file being renamed (see #0654 at AH=11h)
  8317. 335h 331 BYTEs    critical error stack
  8318. 480h 384 BYTEs    disk stack (functions greater than 0Ch, INT 25,INT 26)
  8319. 600h 384 BYTEs    character I/O stack (functions 01h through 0Ch)
  8320. 780h    BYTE    device driver lookahead flag (usually printer) (see AH=64h)
  8321. 781h    BYTE    volume change flag
  8322. 782h    BYTE    flag: virtual open
  8323. 783h    BYTE    ???
  8324. 784h    WORD    ???
  8325. 786h    WORD    ???
  8326. 788h    WORD    ???
  8327. 78Ah    WORD    ???
  8328. SeeAlso: #0967,#0969
  8329. --------D-215E00-----------------------------
  8330. INT 21 - DOS 3.1+ network - GET MACHINE NAME
  8331.     AX = 5E00h
  8332.     DS:DX -> 16-byte buffer for ASCII machine name
  8333. Return: CF clear if successful
  8334.         CH = validity
  8335.         00h name invalid
  8336.         nonzero valid
  8337.             CL = NetBIOS number for machine name
  8338.             DS:DX buffer filled with blank-paded name
  8339.     CF set on error
  8340.         AX = error code (01h) (see #0960 at AH=59h)
  8341. Note:    supported by OS/2 v1.3+ compatibility box, PC-NFS
  8342. SeeAlso: AX=5E01h
  8343. --------N-215E00-----------------------------
  8344. INT 21 - 10NET v5.0 - GET MACHINE NAME
  8345.     AX = 5E00h
  8346. Return: CL = redirector's NetBIOS name number
  8347.     ES:DI -> network node ID
  8348. SeeAlso: AX=5E01h"10NET"
  8349. --------D-215E01CH00-------------------------
  8350. INT 21 - DOS 3.1+ network - SET MACHINE NAME
  8351.     AX = 5E01h
  8352.     CH = 00h undefine name (make it invalid)
  8353.        <> 0     define name
  8354.     CL = name number
  8355.     DS:DX -> 15-character blank-padded ASCIZ name
  8356. SeeAlso: AX=5E00h
  8357. --------N-215E01-----------------------------
  8358. INT 21 - 10NET v5.0 - GET LOCAL 10NET CONFIGURATION TABLE
  8359.     AX = 5E01h
  8360.     CX = length of buffer
  8361.     DS:DX -> buffer for 10Net configuration table (see #821)
  8362. SeeAlso: AX=5E00h"10NET",INT 6F/AH=02h,INT 6F/AH=03h
  8363.  
  8364. Format of 10Net Configuration Table:
  8365. Offset    Size    Description    (Table 0971)
  8366.  00h  8 BYTEs    user name
  8367.  08h 15 BYTEs    node ID
  8368.  17h  3 BYTEs    unique portion of Ethernet address
  8369.  1Ah    BYTE    Who group number
  8370.  1Bh    WORD    services mask (see #0973)
  8371.  1Dh    DWORD    serial number
  8372.  21h    BYTE    maximum concurrent users with same serial number allowed on net
  8373.  22h    BYTE    chat mask (see #0974)
  8374.  23h    BYTE    internal system bits (see #0975)
  8375.  24h  9 BYTEs    version number in format MM.mm.xxx
  8376.  2Dh    BYTE    flag: 01h if machine is a PS/2
  8377.  2Eh    BYTE    flag: 03h if 80386
  8378.  2Fh    BYTE    spool termination mode: 01h concatenate, 02h truncate
  8379.         (see AX=5D09h)
  8380.  30h    WORD    autospool timeout in clock ticks
  8381.  32h    WORD    monitor timeout in clock ticks
  8382.  34h    WORD    unused
  8383.  36h    WORD    chat timeout in clock ticks
  8384.  38h    WORD    netBIOS session timeout in half-seconds
  8385.  3Ah    WORD    datagram send timeout in seconds
  8386.  3Ch    WORD    keyboard value for initiating chat mode
  8387.  3Eh    WORD    Who timeout in clock ticks
  8388.  40h    BYTE    flag: 01h if server should process rom NetBIOS Post return
  8389.  41h    BYTE    flag: 01h if FCBs should be recycled
  8390.  42h  3 BYTEs    signature "DBG"
  8391.  45h    BYTE    last interrupt (21h or 6Fh)
  8392.  46h    BYTE    last INT 21 AH value
  8393.  47h    BYTE    last INT 6F AH value
  8394.  48h    WORD    last item posted
  8395.  4Ah    WORD    last item free-posted
  8396.  4Ch    WORD    last item handled by server
  8397.  4Eh    WORD    last redirector send NCB
  8398.  50h    WORD    last redirector receive NCB
  8399.  52h  4 BYTEs    signature "TABL"
  8400.  56h    WORD    offset of datagram buffer table header (see #0972)
  8401.  58h    WORD    offset of chat buffer table header (see #0972)
  8402.  5Ah    WORD    offset of Raw buffer table header (see #0972)
  8403.  5Ch    WORD    offset of Workstation buffer table header (see #0972)
  8404.  5Eh    WORD    offset of server receive-any table header (see #0972)
  8405.  60h    WORD    offset of Tiny buffer table header (see #0972)
  8406.  62h    WORD    offset of zero-length buffer table (NCBs) (see #0972)
  8407.  64h    WORD    offset of Rdr (Redirector Mount) table header (see #0972)
  8408.  66h    WORD    offset of Ntab (Redirector Session) table header (see #0972)
  8409.  68h    WORD    offset of FCB table header (see #0972)
  8410.  6Ah    WORD    offset of user file handle table header (see #0972)
  8411.  6Ch    WORD    offset of workstation printer RDR extension table header
  8412.  6Eh    WORD    offset of server shared device table header (see #0972)
  8413.  70h    WORD    offset of server connection table header (see #0972)
  8414.  72h    WORD    offset of server login table header (see #0972)
  8415.  74h    WORD    offset of server file table header (see #0972)
  8416.  76h    WORD    offset of server shared file table header (see #0972)
  8417.  78h    WORD    offset of server record lock table header (see #0972)
  8418.  7Ah    WORD    offset of remote printer claim table header (see #0972)
  8419.  7Ch    WORD    offset of remote printer device table header (see #0972)
  8420.  7Eh    WORD    offset of print server mount table header (see #0972)
  8421.  80h    WORD    offset of print server sessions table header (see #0972)
  8422.  82h    WORD    offset of print server print job structure table header
  8423.  84h    WORD    offset of print server pooled device table header (see #0972)
  8424.  86h    WORD    size of workstation buffer
  8425.  88h    WORD    size of server receive-any buffer
  8426.  8Ah    WORD    size of server raw I/O buffer
  8427.  8Ch  6 BYTEs    reserved
  8428.  92h    DWORD    pointer to profile pathname
  8429.  96h    BYTE    datagram retry count
  8430.  97h    BYTE    NetBIOS LAN adapter number
  8431.  98h  6 BYTEs    physical Ethernet address
  8432.  9Eh    BYTE    NetBIOS server name number
  8433.  9Fh    BYTE    NetBIOS redirector name number
  8434.  A0h    BYTE    10Net interrupt number
  8435.  A1h    BYTE    flag: chat is loaded
  8436.  A2h    BYTE    flag: INT 6F APIs permanently loaded
  8437.  A3h    BYTE    flag: file security present
  8438.  A4h    WORD    reserved
  8439.  A6h    BYTE    fixed mount bitmask for drives A:-H:
  8440.  A7h    BYTE    reserved
  8441.  A8h    WORD    10Net system flags (see #0976)
  8442.  AAh    BYTE    monitor flags (see #0977)
  8443.  ABh  5 BYTEs    reserved
  8444.  B0h    WORD    offset of monitor timer block
  8445.  B2h    WORD    offset of server timer block
  8446.  B4h    WORD    offset of chat timer block
  8447.  B6h    WORD    timer chain
  8448.  B8h  4 BYTEs    signature "TALS"
  8449.  BCh    WORD    number of 10Net sends
  8450.  BEh    WORD    number of 10Net receives
  8451.  C0h    WORD    number of no-buffer conditions
  8452.  C2h    WORD    number of dropped posted messages
  8453.  C4h    WORD    number of server NCB errors
  8454.  C6h    WORD    number of redirector NCB errors
  8455.  C8h    WORD    number of datagram send/receive errors
  8456.  CAh    WORD    number of dropped Whos
  8457.  CCh    WORD    number of dropped submits
  8458.  CEh    WORD    number of session aborts
  8459.  D0h    BYTE    number of NetBIOS interface-busy errors
  8460.  D1h    BYTE    last NetBIOS bad post command
  8461.  D2h    BYTE    last NetBIOS bad redirector command
  8462.  D3h    BYTE    do send datagram send/receive error command
  8463.  D4h    DWORD    -> DOS system parameter table
  8464.  D8h    WORD    number of DOS physical drives
  8465.  DAh    WORD    offset of DOS PSP field in DOS data segment
  8466.  DCh    WORD    offset of in-DOS flag in DOS data segment
  8467.  DEh    WORD    DOS data segment
  8468.  E0h    WORD    offset of DOS SFT in DOS data segment
  8469.  E2h    WORD    offset of number-of-physical-units field in DOS data segment
  8470.  E4h    WORD    10Net code segment
  8471.  E6h    WORD    10Net data segment
  8472.  E8h    WORD    10Net common server segment
  8473.  EAh    WORD    10Net file server segment
  8474.  ECh    WORD    10Net print server segment
  8475.  EEh    WORD    10Net remote printer segment
  8476. Note:    documentation lists field at offset D0h as a WORD, but all following
  8477.       offsets are as though it were a BYTE; if it is indeed a WORD, all
  8478.       offsets after D0h must be increased by one byte
  8479.  
  8480. Format of 10Net Table Header:
  8481. Offset    Size    Description    (Table 0972)
  8482.  -16  4 BYTEs    table identifier
  8483.  -12    WORD    peak number of tables allocated
  8484.  -10    WORD    number of tables currently in use
  8485.  -8    WORD    total number of tables
  8486.  -6    WORD    size of each table
  8487.  -4    WORD    offset of first allocated table
  8488.  -2    WORD    offset of first free table
  8489.  
  8490. Bitfields for 10NET services mask:
  8491. Bit(s)    Description    (Table 0973)
  8492.  0    workstation
  8493.  1    file server
  8494.  2    print queue server
  8495.  3    de-spool server
  8496.  
  8497. Bitfields for 10NET chat mask:
  8498. Bit(s)    Description    (Table 0974)
  8499.  0    chat permitted
  8500.  1    bell enabled
  8501.  2    chat keyboard initiated
  8502.  3    in INT 16 handler
  8503.  4    in Get Input
  8504.  5    display has timed out
  8505.  6    chat is idle
  8506.  
  8507. Bitfields for 10NET internal system bits:
  8508. Bit(s)    Description    (Table 0975)
  8509.  0    submit permitted
  8510.  1    submit initiated
  8511.  2    submit executing
  8512.  3    internal client call/chat/spool/autospool
  8513.  4    in spool termination
  8514.  5    print permitted
  8515.  6    waiting for keyboard input
  8516.  
  8517. Bitfields for 10NET System Flags:
  8518. Bit(s)    Description    (Table 0976)
  8519.  0    in NetBIOS
  8520.  1    processing INT 28
  8521.  2    is server
  8522.  3    in net user-DOS function
  8523.  4    in DOS user-DOS function
  8524.  5    in net for user non-DOS function
  8525.  6    in server DOS function
  8526.  7    in server non-DOS function
  8527.  8    in terminate
  8528.  10    in user on server request
  8529.  13    in DOS for user on server
  8530.  14    disable critical error handler
  8531.  
  8532. Bitfields for Monitor Flags:
  8533. Bit(s)    Description    (Table 0977)
  8534.  0    waiting for monitor response
  8535.  4    in monitor get-input routine
  8536.  5    monitor display timeout
  8537.  6    sensing for escape key
  8538. --------D-215E02-----------------------------
  8539. INT 21 - DOS 3.1+ network - SET NETWORK PRINTER SETUP STRING
  8540.     AX = 5E02h
  8541.     BX = redirection list index (see AX=5F02h)
  8542.     CX = length of setup string
  8543.     DS:SI -> setup string
  8544. Return: CF clear if successful
  8545.     CF set on error
  8546.         AX = error code (01h) (see #0960 at AH=59h)
  8547. Note:    also supported by 10NET v5.0
  8548. SeeAlso: AX=5E03h,INT 2F/AX=111Fh
  8549. --------D-215E03-----------------------------
  8550. INT 21 - DOS 3.1+ network - GET NETWORK PRINTER SETUP STRING
  8551.     AX = 5E03h
  8552.     BX = redirection list index (see AX=5F02h)
  8553.     ES:DI -> 64-byte buffer for setup string
  8554. Return: CF clear if successful
  8555.         CX = length of setup string
  8556.         ES:DI buffer filled
  8557.     CF set on error
  8558.         AX = error code (01h) (see #0960 at AH=59h)
  8559. Note:    also supported by 10NET v5.0, but 10NET is documented as using DS:SI
  8560.       instead of ES:DI
  8561. SeeAlso: AX=5E02h,INT 2F/AX=111Fh
  8562. --------D-215E04-----------------------------
  8563. INT 21 - DOS 3.1+ network - SET PRINTER MODE
  8564.     AX = 5E04h
  8565.     BX = redirection list index (see AX=5F02h)
  8566.     DX = mode
  8567.         bit 0: set if binary, clear if text (tabs expanded to blanks)
  8568. Return: CF set on error
  8569.         AX = error code (see #0960 at AH=59h)
  8570.     CF clear if successful
  8571. Note:    calls INT 2F/AX=111Fh with 5E04h on stack
  8572. SeeAlso: AX=5E05h"DOS",INT 2F/AX=111Fh
  8573. --------N-215E04-----------------------------
  8574. INT 21 - 10NET v5.0 - INITIATE PRINT JOB
  8575.     AX = 5E04h
  8576.     BX = zero-based redirection list index (see AX=5F02h)
  8577.     DS:DX -> extended workstation printer setup structure (see #0978)
  8578. Return: CF clear if successful
  8579.     CF set on error
  8580.         AX = error code (see #0960 at AH=59h)
  8581. SeeAlso: AX=5E05h"10NET",AX=5E06h"10NET"
  8582.  
  8583. Format of 10NET extended workstation printer setup structure:
  8584. Offset    Size    Description    (Table 0978)
  8585.  00h    BYTE    notification flags (see #0979)
  8586.  01h    BYTE    job control mask (see #0980)
  8587.  02h    WORD    days to retain file
  8588.  04h    WORD    test print length
  8589.  06h    BYTE    number of copies to print
  8590.  07h    BYTE    compression algorithm
  8591.  08h    BYTE    tab width (00h = don't expand)
  8592.  09h    BYTE    initiation type (00h normal, 01h non-spooled)
  8593.  0Ah 38 BYTEs    job start operation notification instructions
  8594.  30h 32 BYTEs    comment for job
  8595.  50h 64 BYTEs    output filename or non-spooled file
  8596.  
  8597. Bitfields for 10NET notification flags:
  8598. Bit(s)    Description    (Table 0979)
  8599.  0    user at print start
  8600.  1    operator at start, with reply
  8601.  2    user at print completion
  8602.  3    operator at completion, with reply
  8603.  4    user on queue switch
  8604.  5    operator on queue switch, with reply
  8605.  6    user on print error
  8606.  
  8607. Bitfields for 10NET job control mask:
  8608. Bit(s)    Description    (Table 0980)
  8609.  0    print banner page
  8610.  1    eject page at end of job
  8611.  2    mark as "held" (queue but don't print)
  8612.  3    rush job (queue at top)
  8613.  4    overwrite file with zeros before deletion
  8614.  5    hyperspool if possible
  8615. --------D-215E05-----------------------------
  8616. INT 21 - DOS 3.1+ network - GET PRINTER MODE
  8617.     AX = 5E05h
  8618.     BX = redirection list index (see AX=5F02h)
  8619. Return: CF set on error
  8620.         AX = error code (see #0960 at AH=59h)
  8621.     CF clear if successful
  8622.         DX = printer mode (see AX=5E04h)
  8623. Note:    calls INT 2F/AX=111Fh with 5E05h on stack
  8624. SeeAlso: AX=5E04h"DOS",INT 2F/AX=111Fh
  8625. --------N-215E05-----------------------------
  8626. INT 21 - 10NET v5.0 - TERMINATE PRINT JOB
  8627.     AX = 5E05h
  8628.     BX = zero-based redirection list index (see AX=5F02h)
  8629. Return: CF clear if successful
  8630.     CF set on error
  8631.         AX = error code (see #0960 at AH=59h)
  8632. Note:    this call resets the spool termination mode to "truncate"
  8633.       (see AX=5D08h)
  8634. SeeAlso: AX=5E04h"10NET",AX=5E06h
  8635. --------N-215E06-----------------------------
  8636. INT 21 - 10NET v5.0 - GET/SET 10NET WORKSTATION PRINTER SETUP STRUCTURE
  8637.     AX = 5E06h
  8638.     BX = zero-based redirection list index (see AX=5F02h)
  8639.     CX = operation (06h set, 07h get)
  8640.     DS:DX -> buffer for setup structure (same as first nine bytes of
  8641.           workstation printer setup) (see #0978)
  8642. Return: CF clear if successful
  8643.         DS:DX buffer updated on get
  8644.     CF set on error
  8645.         AX = error code (see #0960 at AH=59h)
  8646. SeeAlso: AX=5E04h"10NET",AX=5E05h"10NET"
  8647. --------!---Section--------------------------
  8648.